Mutesa-Cedric / react-swift-reveal

React-swift-reveal is a React component library and animation framework for animating elements as they enter the viewport and onscroll
https://react-swift-reveal.vercel.app
MIT License
45 stars 3 forks source link
animations collaborate reveal-animations scroll-animations

react-swift-reveal

react-swift-reveal is a React component library and animation framework for animating elements as they enter the viewport.

for more, check the documentation

Installation

with npm:

npm install react-swift-reveal

with yarn:

yarn add react-swift-reveal

with pnpm:

pnpm add react-swift-reveal

Usage

import { Fade } from "react-swift-reveal";

const App = () => {
  return (
    <Fade>
      <h1>hello world</h1>
    </Fade>
  );
};

or

import { Fade } from "react-swift-reveal";

const App = () => {
  return (
    <Fade>
      <MyComponent /> //component to be animated
    </Fade>
  );
};

with next.js app directory

"use client";

import { Fade } from "react-swift-reveal";

export default function Home() {
  return (
    <Fade>
      <h1>hello world</h1>
    </Fade>
  );
}

Available Animations

Simple animations

Support

If you like this project, please consider supporting it by giving it a star.