Skip to content

Instantly share code, notes, and snippets.

@alejandrocoding
Created June 12, 2020 23:40
Show Gist options
  • Save alejandrocoding/d13accc8eb6ece34694d28e300560781 to your computer and use it in GitHub Desktop.
Save alejandrocoding/d13accc8eb6ece34694d28e300560781 to your computer and use it in GitHub Desktop.
Chrome Extension angular.json with live reload only in dev mode
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
...
"projects": {
"chrome-extension-template": {
...
"architect": {
"build": {
"builder": "@angular-builders/custom-webpack:browser",
"options": {
...
"aot": true,
"vendorChunk": false,
"assets": [
"src/favicon.ico",
"src/assets",
"src/manifest.json"
],
"styles": [
"src/styles.scss"
],
"scripts": [],
"customWebpackConfig": {
"path": "./custom-webpack-dev.config.js"
}
},
"configurations": {
"production": {
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
...
"vendorChunk": false,
"buildOptimizer": true,
"customWebpackConfig": {
"path": "./custom-webpack.config.js"
},
...
}
}
},
...
...
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment