Pretty and easy-to-use modal window implemented via react. You can freely use the code in your projects.
Note
Switch between branches to view the code
The repository has an example of using a modal. There is a separate custom hook called UseModal
for this. The Portal
built-in react is also used, which redirects the modal to the root-modals
.
To try out the project (along with a test login form) run the following commands in the terminal:
git clone -b [javascript | typesript] https://github.com/DanieloM83/React-Modal-Component.git
cd React-Modal-Component
npm install -g yarn # npm comes bundled with Node.js
yarn # download all dependencies (may take some time)
yarn dev # start the project
This will launch the project on your local machine, and you can access it by navigating to (usually) http://localhost:5173 in your web browser.
I want to thank the community of YouTube authors for their great contribution to the creation of this small project.