Struggling with maintaining class names when compiling in production mode using Angular 7? I've tried various settings in the Terser plugin, but none seem to solve this issue. Is there a workaround for this problem? Perhaps an alternative to MyClass.constructor.name?
Any help is greatly appreciated.
Check out my custom Webpack configuration below:
const TerserPlugin = require('terser-webpack-plugin');
module.exports = {
optimization: {
minimizer: [
new TerserPlugin({
parallel: true,
terserOptions: {
keep_classnames: true,
mangle: false
}
})
]
}
};
- @angular-builders/custom-webpack": "^7.1.1"
- @angular-devkit/build-angular": "^0.11.2"
- @angular/cli": "^7.0.4",