forge
forge copied to clipboard
Unable to override webpack-dev-server client.overlay configuration for renderer process
Pre-flight checklist
- [X] I have read the contribution documentation for this project.
- [X] I agree to follow the code of conduct that this project uses.
- [X] I have searched the issue tracker for a bug that matches the one I want to file, without success.
Electron Forge version
6.2.1
Electron version
25.2.0
Operating system
macOS
Last known working Electron Forge version
No response
Expected behavior
Override webpack devServer.client.overlay config
Actual behavior
Adding
devServer: {
client: {
overlay: false
}
}
to webpack.renderer.config.ts has no effect at runtime - I continue to get overlay errors with this configuration set.
Steps to reproduce
- electron-forge project with webpack-typescript template + add react capability
- trigger a runtime error in the renderer code a. I have been getting this in project after configuring a two panel layout with react-split and react-monaco-editor in the right pane (without automaticLayout: true). Running the application and using the resizable divider leads to "ResizeObserver loop limit detected" runtime error. From what I can tell this is benign (which is wanted to suppress this error).
- still observe the overlay for runtime error despite configuring it to not show. I've also observed this in the various forms of trying to disable the error (overlay: { runtimeErrors: false }, overlay: { runtimeErrors: (error) => {...} })
Additional information
This seems potentially related to #2599
I am also affected by this problem. I solved it by adding a CSS rule to my page that just sets display: none on the iframe that Webpack injects for the overlay.
#webpack-dev-server-client-overlay {
display: none;
}
try, this works for me
devServer: {
client: {
overlay: {
errors: false,
warnings: false
}
}