🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

react-router-modal

Package Overview
Dependencies
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-router-modal - npm Package Compare versions

Comparing version

to
1.3.1

19

docs/preamble.md

@@ -52,1 +52,20 @@ A simple way to handle showing modals with react-router version 4.

4. Navigate to /modal-test in your app. You should see a Modal with the contents "Hello".
### Gotchas
#### My modals are not showing at all
1. Did you render a ModalContainer?
2. Did you include the CSS to style the modals and their backdrops?
#### I see my modal content but the component "behind" it is not rendering.
To display a modal component "on top" of another component, *both* routes (the ModalRoute and the Route that renders the other component) must match.
If you are seeing modal content but the component that you expect to see "behind" the modal is not rendering, you should check for the following:
1. Did you put both routes inside a `<Switch />`, so only one of them matches?
2. Did you use `exact` on the `<Route />` that contains the component that is meant to render "under" the modal?

2

package.json
{
"name": "react-router-modal",
"version": "1.3.0",
"version": "1.3.1",
"description": "simple react router modal",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -66,3 +66,21 @@ <!-- Generated by documentation.js. Update this documentation by updating the source code. -->

### Gotchas
#### My modals are not showing at all
1. Did you render a ModalContainer?
2. Did you include the CSS to style the modals and their backdrops?
#### I see my modal content but the component "behind" it is not rendering.
To display a modal component "on top" of another component, _both_ routes (the ModalRoute and the Route that renders the other component) must match.
If you are seeing modal content but the component that you expect to see "behind" the modal is not rendering, you should check for the following:
1. Did you put both routes inside a `<Switch />`, so only one of them matches?
2. Did you use `exact` on the `<Route />` that contains the component that is meant to render "under" the modal?
## Examples

@@ -69,0 +87,0 @@

Sorry, the diff of this file is not supported yet