Skip to content

Commit

Permalink
docs(readme.md): minimal example children as prop
Browse files Browse the repository at this point in the history
  • Loading branch information
GH Pages Bot committed Apr 7, 2019
1 parent 657b0eb commit 5ce2936
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ import MicroModal from 'react-micro-modal';

const App = () => {
return (
<MicroModal trigger={handleOpen => <div onClick={handleOpen}>Open!</div>}>
{handleClose => <button onClick={handleClose}>Close!</button>}
</MicroModal>
<MicroModal
trigger={handleOpen => <div onClick={handleOpen}>Open!</div>}
children={handleClose => <button onClick={handleClose}>Close!</button>}
/>
);
};

Expand Down

0 comments on commit 5ce2936

Please sign in to comment.