RangeError on build step
See original GitHub issueI get the follow errors on production (I am using next.js) when I run next build
:
Failure loading font http://localhost:3000/models/digital-7-mono.ttf; trying fallback RangeError: Offset is outside the bounds of the DataView
at DataView.getUint16 (<anonymous>)
etc...
Failure loading font https://fonts.gstatic.com/s/roboto/v18/KFOmCnqEu92Fr1Mu4mxM.woff RangeError: Offset is outside the bounds of the DataView
at DataView.getUint16 (<anonymous>)
etc...
When running next dev
this error doesn’t come up.
-I am using troika-three-text via the drei <Text /> component. I found out this uses the preloadFont
function as well, I am not sure that that is relevant, but just in case it is.
-Error happens both in Chrome and Safari.
Issue Analytics
- State:
- Created a year ago
- Reactions:3
- Comments:9
Top Results From Across the Web
Maximum call stack size exceeded ' when run build · Issue ...
Then I detele some router. it build work. ... 'RangeError: Maximum call stack size exceeded ' when run build #3091 ... Steps to...
Read more >RequireJS build error [RangeError: Maximum call stack size ...
I ran into this problem with requireJS 2.1.15. The problem seemed to be that the html extension was not part of the of...
Read more >FAQ — Emscripten 3.1.26-git (dev) documentation
What is “No WebAssembly support found. Build with -sWASM=0 to target JavaScript instead” or “no native wasm support detected”?¶ ... Those errors indicate...
Read more >JavaScript Error: Maximum Call Stack Size Exceeded
This error is a RangeError. A RangeError typically means an error has occurred outside of a code's argument value for its parameter. Now...
Read more >RangeError: Maximum call stack size exceeded - Educative.io
In this shot, we will see how to fix the “RangeError: Maximum call stack size exceeded” error. ... The most common source for...
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 FreeTop 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
Top GitHub Comments
Here’s a reproducible example: https://stackblitz.com/edit/nextjs-fznkmq?file=package.json,next.config.js
I’ve narrowed it down to the options
swcMinify
andnext
version12.3.1
. Steps to reproduce:swcMinify: true
in next.config.js.yarn && yarn next build && yarn next start
.The error is gone when
swcMinify: false
.Another issue that manifested in different behaviours on prod and dev builds, which might be related, is https://github.com/pmndrs/react-three-fiber/issues/2533.
I’m seeing this issue in next.js 13.0.3 did anyone found a solution? it only happens in production. It runs fine in
next dev