modal-sheet
Version:
### Simple react native modal sheet
41 lines (25 loc) • 603 B
Markdown
using yarn : `yarn add modal-sheet` <br>
using npm : `npm i modal-sheet`
```JSX
import Modal from 'modal-sheet';
const ref = useRef(null)
const onOpen = () => ref.current.open()
const onClose = () => ref.current.close()
// ...
<Modal ref={ref} size="m">
{children}
</Modal>
// ...
```
| Props | Require | Description |
| ----- | ------- | ---------------------------- |
| size | no | `"s"`, `"m"` ,`"l"` , `"xl"` |
Open Modal
Close Modal