2.1.10 • Published 2 years ago
@midly/react-modall v2.1.10
React-modal
React-modal is a simplest way to create dialog on your ReactJS site.
- Small (less than 45Kb)
- Mobile friendly
- Without dependencies
Getting Started
Install this package:
npm i @midly/react-modal
Import the component:
import {Modal} from '@midly/react-modal';
import {ModalRef} from '@midly/react-modal/dist/esm/Modal'
const modalRef = useRef<ModalRef>(null)
<Modal ref={modalRef}>Your content</Modal>
You can then render the Modal component like any other React component in JSX.
const showModal = useCallback<SubmitHandler>(() => modalRef.current?.open(), [])
<button className="button" onClick={showModal}>Open modal</button>
2.1.10
2 years ago
2.1.9
2 years ago
2.1.8
2 years ago
2.1.7
2 years ago
2.1.6
2 years ago
2.1.4
2 years ago
2.1.3
2 years ago
1.1.2
2 years ago
1.1.1
2 years ago
1.0.18
2 years ago
1.0.17
2 years ago
1.0.16
2 years ago
1.0.15
2 years ago
1.0.14
2 years ago
1.0.13
2 years ago
1.0.12
2 years ago
1.0.11
2 years ago
1.0.10
2 years ago
1.0.9
2 years ago
1.0.8
2 years ago
1.0.7
2 years ago