react-simple-modal
React modal make it simple.
How use it
Download it with:
npm i -S react-simple-modal
Then import it in your code:
;
Now you can use it as any React component.
Enjoy!
Props
className
Define your own className property to the modal, must be a string, is optional, default 'Modal'.
onClickOverlay
A function to be called when the user clicked the overlay, must be a function, is required.
opacity
Define the opacity of the overlay, must be a number between 0 and 1, is optional, default 0.5
.
visible
Define is the Modal is visible, must be a boolean, is required.
Example
;; const App = React; React;