Fix unreliable `window` and `document` detection by viktorbezdek · Pull Request #246 · google-map-react/google-map-react
- Dammit, I committed compiled files to my fork just to be able to use my fork as a dependency temporarily before you publish the patch. Should have make topic branch for the pull request.
- One of the cases is quite simple - my application have to use private module that I have no control of. This module requires global variable window with some unrelated data, so
typeof window !== 'undefined'become truthy and SSR breaks. New solution only makes deeper more robust checking. There is another, more tricky, case but I have to debug my app I bit more to make sure it's not issue on my side.
I'll fix files in the repo in sec. Will let you know.