### Summary: Fails when rendering using `renderToStaticMarkup` ### Steps to reproduce: call `renderToStaticMarkup` with `react-modal` anywhere in the tree ### Expected behavior: ### Link to example of issue: https://codesandbox.io/s/rwnvq00p8p ### Additional notes: I have made a failing test [here](https://github.com/salzhrani/react-modal/tree/static-markup)