Last active
September 10, 2019 11:58
-
-
Save rajaramtt/528d7a150a72c5f5a1b2bf906f0b0f97 to your computer and use it in GitHub Desktop.
Stage environment setup in angular
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"configurations": { | |
"production": { ... }, | |
"staging": { | |
"fileReplacements": [ | |
{ | |
"replace": "src/environments/environment.ts", | |
"with": "src/environments/environment.staging.ts" | |
} | |
] | |
} | |
} | |
// ng build --configuration=staging | |
"serve": { | |
"builder": "@angular-devkit/build-angular:dev-server", | |
"options": { | |
"browserTarget": "your-project-name:build" | |
}, | |
"configurations": { | |
"production": { | |
"browserTarget": "your-project-name:build:production" | |
}, | |
"staging": { | |
"browserTarget": "your-project-name:build:staging" | |
} | |
} | |
}, | |
// ng serve --configuration=staging | |
// Referance URL: https://angular.io/guide/build#using-environment-specific-variables-in-your-app | |
architect": { | |
"build": { | |
"builder": "@angular-devkit/build-angular:browser", | |
"options": { | |
"outputPath": "dist/test", | |
"assets": [ | |
"src/favicon.ico", | |
"src/assets", | |
"src/lib", | |
"src/zoom", | |
"src/lib/av/" | |
], | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment