document is not defined
See original GitHub issueDescription
v.0.3.0 in a razzlejs build with ssr balks when I add remirror editor to the mix. The renderer is working just fine.
ReferenceError: document is not defined
at createCache (/Volumes/Data/razzle-demo/node_modules/@remirror/react-ssr/lib/dist/react-ssr.esm.js:1191:1)
at Module.../node_modules/@remirror/react-ssr/lib/dist/react-ssr.esm.js (/Volumes/Data/razzle-demo/build/webpack:/node_modules/@remirror/react-ssr/lib/dist/react-ssr.esm.js:1696:1)
Possible Fix
🤷♂ I can’t find any reference to document in the codebase so I don’t know what’s going on.
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
ReferenceError: document is not defined (in plain JavaScript)
Explanation: The error is caused because NextJs renders the page in the server only and in the server document (document is used inside...
Read more >How to fix ReferenceError: Document is not defined ... - Sabe.io
The most common reason for getting the reference error while on the browser is when you try to access the document object too...
Read more >ReferenceError: document is not defined in JavaScript
The "ReferenceError: document is not defined" error occurs for multiple reasons: ... The document relates to the document object which represents a web...
Read more >ReferenceError: document is not defined in JavaScript
The "ReferenceError: document is not defined" error is thrown when the code tries to access the document object, but the object is not ......
Read more >How to solve the document is not defined error - Flavio Copes
Here's how to fix the “referenceerror: document is not defined” error that you might have in Node.js or with a tool like Next.js....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@hennessyevan I’ve managed to find a fix for this. It’ll be available in the next release.
It’s a sneaky one and would likely have caused a lot of issues down the line so I appreciate you raising it.
I’ve added a brief explanation to #115 in case your interested 👍
Fantastic!