-
-
Notifications
You must be signed in to change notification settings - Fork 232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
document is not defined #102
Comments
@hennessyevan I'll look into this. You don't by any chance have a sandbox I could look at? |
It's coming from this line in emotion which is strange but I think it's this issue emotion-js/emotion#1246, not anything about remirror. I'll keep this open until I figure it out and then post my findings here |
I don’t know much about rollup but is this a similar setting to webpack’s target? https://github.com/ifiokjr/remirror/blob/master/support/rollup/factory.js#L32 The emotion issue’s solution seems to be bundling with the ‘node’ target so that ‘isBrowser’ becomes false in ‘esm’. I’ll check against my fork |
Yeah so I forked it and changed the browser setting but to no avail. It seems the @emotion/cache package gets bundled by https://github.com/preconstruct/preconstruct/blob/5674b34ca7ed9e46c7db4526eed249441089b0d3/src/build/rollup.js#L212 and In the |
@hennessyevan I'm looking at this now and have replicated your error.
I've created a No guarantees, but I'll see if I can find a solution before the next release at some point this weekend. |
@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! |
Description
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.
Possible Fix
🤷♂ I can't find any reference to document in the codebase so I don't know what's going on.
The text was updated successfully, but these errors were encountered: