Skip to content

Latest commit

 

History

History
79 lines (61 loc) · 1.65 KB

readme.md

File metadata and controls

79 lines (61 loc) · 1.65 KB

react-page-transition

Drop in page transition component built for hooks

preview


Installation

$ npm install --save react-page-transition
$ yarn add react-page-transition

Usage

import * as React from 'react'
import Pager from 'react-page-transition'

export default function App() {
  const [value, setState] = React.useState(0);

  return (
    <Pager value={value} onRequestChange={i => setState(i)}>
      <div>Hey!</div>
      <Component2 />
      {(props, index) => {
        return 'I also work!';
      }}
    </Pager>
  );
}

Example

Edit react-page-transition

$ yarn example

Questions? Feedback? Please let me know

License (MIT)

WWWWWW||WWWWWW
 W W W||W W W
      ||
    ( OO )__________
     /  |           \
    /o o|    MIT     \
    \___/||_||__||_|| *
         || ||  || ||
        _||_|| _||_||
       (__|__|(__|__|