What is this?
Introduction
This is a Simple Modal Solution for React. Wrap your top level component(usuaully App.js) with ModalProvider and useModal hook will be available to use. npm
Features
- Open modal by using function call that returns result as promise.
- Open multiple modals at the same time.
- Close all modals at the same time.
- Close modal by clicking outside of modal.
- Close modal when popstate event is fired.(ex. browser back button)
- Control scroll action when modal is open.(ex. disable scroll)
- Full Typescript support.
- No dependencies except React.