-
Notifications
You must be signed in to change notification settings - Fork 12k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(@angular/cli): use environmentSource key for environments #4705
Conversation
3bd4ed2
to
6e7f840
Compare
An alias should be added in
|
Heavily based on @jsanchezgarcia work in angular#4476. Fix angular#3857 BREAKING CHANGE: A new environmentSource entry replaces the previous source entry inside environments. To migrate the code follow the example below: Before: ``` "environments": { "source": "environments/environment.ts", "dev": "environments/environment.ts", "prod": "environments/environment.prod.ts" } ``` After: ``` "environmentSource": "environments/environment.ts", "environments": { "dev": "environments/environment.ts", "prod": "environments/environment.prod.ts" } ```
6e7f840
to
1b3a5dd
Compare
@@ -19,15 +19,16 @@ function _createAotPlugin(wco: WebpackConfigOptions, options: any) { | |||
let hostOverrideFileSystem: any = {}; | |||
// process environment file replacement | |||
if (appConfig.environments) { | |||
if (!('source' in appConfig.environments)) { | |||
throw new SilentError(`Environment configuration does not contain "source" entry.`); | |||
if (!appConfig.environmentSource) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please verify if environment.source
is set here and explain to the user the change s/he needs to make.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
…ar#4705) Heavily based on @jsanchezgarcia work in angular#4476. Fix angular#3857 BREAKING CHANGE: A new environmentSource entry replaces the previous source entry inside environments. To migrate the code follow the example below: Before: ``` "environments": { "source": "environments/environment.ts", "dev": "environments/environment.ts", "prod": "environments/environment.prod.ts" } ``` After: ``` "environmentSource": "environments/environment.ts", "environments": { "dev": "environments/environment.ts", "prod": "environments/environment.prod.ts" } ```
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Heavily based on @jsanchezgarcia work in #4476.
Fix #3857
BREAKING CHANGE:
A new
environmentSource
entry replaces the previoussource
entry insideenvironments
.To migrate the code follow the example below:
Before:
After: