We can create reusable modal component without importing additional library.

In this demo, We create a single component and passing the Modal Title and Contents through props from parent component. I use Bootstrap 4 for better UI.

Demo:

http://react-modal.amasik.com/

Source:

https://github.com/mail2asik/react-modal