You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I agree to follow the code of conduct that this project uses.
I have searched the issue tracker for a feature request that matches the one I want to file, without success.
Problem description
We are using bugsnag to capture errors from our electron app. At build time, we need to upload the sourcemaps that webpack produces to bugsnag, however we don't want to ship our app with those sourcemaps.
At present we accomplish this by providing an ignore function in the packagerConfig, however this function is mostly a copy of what is already in @electron-forge/webpack-plugin
Proposed solution
Add a configuration option to WebpackPluginConfig, perhaps
ignoreSourcemaps?: boolean;
Update the forgeConfig.packagerConfig.ignore function in WebpackPlugin.resolveForgeConfig to, if the above-mentioned ignoreSourcemaps config is set, to return true if the filename ends in .map.
Alternatives considered
🤔 Is it ever appropriate to include sourcemaps in an electron app? Perhaps sourcemaps should always be ignored from packaging, or perhaps they should be ignored by default, and the configuration value would let them be included. Of course, a person could specify inline sourcemaps to include them, even if they were default-excluded.
Additional information
I'd be interesting in contributing a PR; I wanted to get feedback on if/how this feature should be exposed.
Thanks!
The text was updated successfully, but these errors were encountered:
Restricts generated source map files from being included in the
packaged application by default. Provides an config option to include
them in again.
Closes: #2573
Pre-flight checklist
Problem description
We are using bugsnag to capture errors from our electron app. At build time, we need to upload the sourcemaps that webpack produces to bugsnag, however we don't want to ship our app with those sourcemaps.
At present we accomplish this by providing an
ignore
function in thepackagerConfig
, however this function is mostly a copy of what is already in@electron-forge/webpack-plugin
Proposed solution
Add a configuration option to
WebpackPluginConfig
, perhapsUpdate the
forgeConfig.packagerConfig.ignore
function inWebpackPlugin.resolveForgeConfig
to, if the above-mentionedignoreSourcemaps
config is set, to returntrue
if the filename ends in.map
.Alternatives considered
🤔 Is it ever appropriate to include sourcemaps in an electron app? Perhaps sourcemaps should always be ignored from packaging, or perhaps they should be ignored by default, and the configuration value would let them be included. Of course, a person could specify inline sourcemaps to include them, even if they were default-excluded.
Additional information
I'd be interesting in contributing a PR; I wanted to get feedback on if/how this feature should be exposed.
Thanks!
The text was updated successfully, but these errors were encountered: