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
Codemirror: RangeError Selection points outside of document #505
Comments
It seems that Nextjs is compiling the @codemirror/text with different outputs: Wrong // next.config.js
swcMinify: true,
// @codemirror/text
constructor(a, b=function(a) {
for (let b of a)
b.length;
return -1
} Correct // next.config.js
swcMinify: false,
// @codemirror/text
constructor(a, b=function(a) {
let e = -1
for (let b of a)
e + b.length + 1;
return e
} So, short answer, set 🤯 |
Hey @grikomsn, please take a look at the answer above, it might solve the problem. I'll try to address this issue with nextjs or swc. |
Tried disabling Footnotes |
Addressed on vercel/next.js#36127 |
Discussed in https://github.com/codesandbox/sandpack/discussions/501
Originally posted by grikomsn June 18, 2022
Recently migrated my Next.js side project from using sandpack v0 to v11 and noticed that for some reason it errors out in production but works on development. Below are screenshots with console logs for both instances.
Besides the console log errors, line numbers do not show and editor is not clickable nor editable. Will attempt debugging whether it's from the UI library or something else.
Development
Production
#465
Footnotes
https://github.com/grikomsn/patterns-run/commit/51e7fd73145e37bff4667796793bf4e631f28e72#diff-55de525accdc1569db9c81113d77df271e051f7c8b9dc882d5268043346a18df
The text was updated successfully, but these errors were encountered: