DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» is a community of 963,274 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Don
Don

Posted on

Customize Angular Webpack config

  1. add customWebpackConfig to angular.json

    {
        "projects": {
            "architect": {
                "build": {
                    "options": {
                      "customWebpackConfig": {
              "path": "./custom-webpack.config.js",
              "replaceDuplicatePlugins": true
            },
                    }
                }
            }
        }
    }
    
  2. add the extra webpack plugin config in the custom-webpack.config.js

    module.exports = {
        module: {
            rules: [
                {
                    test: /\.js$/,
                    loader: 'babel-loader',
                    query: {
                        presets: ['@babel/preset-env'
                        ]
                    }
                }
            ]
        }
    }
    
    

Top comments (0)

Take a look at this:

Settings

Go to your customization settings to nudge your home feed to show content more relevant to your developer experience level. πŸ›