next.js
c2a132b5 - DX: fix error overlay flash (#61813)

Commit
1 year ago
DX: fix error overlay flash (#61813) ### What Skipping module build error and module not found error in `onUnhandledError` handler from pages router dev overlay, to avoid the build error being caught twice by error overlay in both unhandled error and build error type. The unhandled error is slightly eariler than build error, which causes the flash. We skipped it to avoid display same duplicated errors. ### Why This change fixes a flashing UX on error overlay when build error occurred, it will go from a white background with red text to a source panel with actual code where triggered build error, such as synatx error. I recodered two videos to show them properly. Since it happens too fast, hard to address them with test, more like fixing a minor frustration in the UI. ### After https://github.com/vercel/next.js/assets/4800338/59dcde0f-3ac7-419f-ba5c-c28c9d5a7205 ### Before https://github.com/vercel/next.js/assets/4800338/e64e8855-2c5f-43a5-948c-8137cad538a1 Closes NEXT-2403 Closes NEXT-2145
Author
Parents
Loading