-
Notifications
You must be signed in to change notification settings - Fork 28.3k
ReferenceError: xxx is not defined #76802
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
Comments
Related issue: markdown-it/markdown-it#1082 |
I was able to resolve the issue on my end by removing --turbo You may also want to downgrade markdown-it to |
Yes but, how can I use the latest markdown-it WITH turbo? |
Dug into this and found a minimal reproduction: // app/assert.js
export function assert(a, b) {
if (a !== b) {
throw new Error(`Assertion failed: ${a} !== ${b}`);
}
} // app/page.js
import { assert } from "./assert";
const ch = 0x10;
function test() {
for (;;) {
// found valid marker
if (ch === 0x29 /* ) */ || ch === 0x2e /* . */) {
break;
}
return -1;
}
if (1 < 2) {
if (!assert(1, 1)) {
// " 1.test " - is not a list item
return -1;
}
}
return pos;
}
export default function Page() {
return <h1>{test()}</h1>;
} It's very similar to this issue: #77083 My current thinking is that the analysis seems to detect a case where |
Link to the code that reproduces this issue
https://github.com/Cygra/reproduction-example-with-markdown-it
To Reproduce
Current vs. Expected behavior
Current
Expected behavior
The application should start, since the method
isSpace
is defined and exported from the package "markdown-it".Provide environment information
Operating System: Platform: darwin Arch: x64 Version: Darwin Kernel Version 23.6.0: Mon Jul 29 21:13:00 PDT 2024; root:xnu-10063.141.2~1/RELEASE_X86_64 Available memory (MB): 16384 Available CPU cores: 8 Binaries: Node: 20.18.1 npm: 10.8.2 Yarn: N/A pnpm: 9.15.0 Relevant Packages: next: 15.2.2-canary.0 // Latest available version is detected (15.2.2-canary.0). eslint-config-next: N/A react: 19.0.0 react-dom: 19.0.0 typescript: 5.8.2 Next.js Config: output: N/A
Which area(s) are affected? (Select all that apply)
Turbopack
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
The text was updated successfully, but these errors were encountered: