-
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
refactor(@angular/cli): simplify default arguments in angular-cli.json #4389
Conversation
da8ef74
to
2d1d01b
Compare
@@ -117,6 +117,10 @@ class SchemaClassBase<T> implements SchemaClass<T> { | |||
/** Get a value from a JSON path. */ | |||
$$get(path: string): any { | |||
const node = _getSchemaNodeForPath(this.$$schema(), path); | |||
if (path === 'defaults.component.viewEncapsulation') { |
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.
tsk tsk
@@ -406,6 +406,7 @@ export abstract class LeafSchemaTreeNode<T> extends SchemaTreeNode<T> { | |||
|
|||
get() { | |||
if (!this.defined && this._forward) { | |||
console.log('fwd'); |
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.
tsk tsk
@@ -30,7 +30,7 @@ export default Blueprint.extend({ | |||
|
|||
options.spec = options.spec !== undefined ? | |||
options.spec : | |||
this.project.ngConfigObj.get('defaults.spec.class'); | |||
this.project.ngConfigObj.get('defaults.class.spec'); |
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 use an alias for these, and a warning if the alias is used.
See here for an example.
ec17e58
to
80e29b8
Compare
@hansl this PR has been updated addressing the requested changes. |
80e29b8
to
a2c6818
Compare
cliConfig.alias('defaults.component.module', 'defaults.spec.module'); | ||
cliConfig.alias('defaults.component.pipe', 'defaults.spec.pipe'); | ||
cliConfig.alias('defaults.component.service', 'defaults.spec.service'); | ||
|
||
// If any of them returned true, output a deprecation warning. | ||
if (aliases.some(x => !!x)) { |
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.
This warning should also be updated. Maybe it should be a generic warning? Not sure. I have a PR that will also need to do this.
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.
@hansl and I chatted and we decided to leave the remapping of these as silent, as the correct values will still be handled correctly in the config file.
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.
I'll do the same to mine then.
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.
LGTM.
…son defaults Add documentation for a breaking change in angular-cli.json (see angular#4389) that was missed in the changelog Fix angular#4404
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. |
Fixes #4137