未处理的运行时错误 | TypeError:无法读取 null 的属性(读取“CodeMirror”)
2022-11-17
1675
chrome 上的错误图片
使用 Next.js 13
我在 google chrome 上收到此错误,我该如何修复它(或者可能只是忽略它)。
我没有使用 Codemirror,也不想使用它。
我试过:
- 删除“.next”、“node_modules”、“package-lock.json”
- npm cache clear --force
- npm install; npm run dev
$npm list
├── @types/[email protected]
├── @types/[email protected]
├── @types/[email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]
终端:
ready - started server on 0.0.0.0:3000, url: http://localhost:3000
event - compiled client and server successfully in 1259 ms (154 modules)
wait - compiling...
event - compiled successfully in 53 ms (130 modules)
wait - compiling / (client and server)...
event - compiled client and server successfully in 102 ms (183 modules)
wait - compiling /_error (client and server)...
event - compiled client and server successfully in 102 ms (184 modules)
warn - Fast Refresh had to perform a full reload. Read more: https://nextjs.org/docs/basic-features/fast-refresh#how-it-works
TypeError: Cannot read properties of null (reading 'length')
at eval (webpack-internal:///./node_modules/next/dist/client/dev/error-overlay/hot-dev-client.js:262:55)
warn - Fast Refresh had to perform a full reload. Read more: https://nextjs.org/docs/basic-features/fast-refresh#how-it-works
TypeError: Cannot read properties of null (reading 'length')
at eval (webpack-internal:///./node_modules/next/dist/client/dev/error-overlay/hot-dev-client.js:262:55)
3个回答
禁用正在运行的名为 Blackbox 的 chrome 扩展程序
Satish Patil
2022-11-18
可能是以下内容: const hasUpdates = Boolean(updatedModules.length); 只需要是: const hasUpdates = Boolean(updatedModules && updatedModules.length);
Mo lemine Hmd
2022-11-18
如果您正在使用此 chrome 扩展程序:Blackbox - 选择。复制。粘贴和搜索, 您必须禁用它。
ajx
2022-11-18