-
Notifications
You must be signed in to change notification settings - Fork 11.9k
fix(@angular/cli): set inlineTemplate and inlineStyle for minimal projects #16988
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
Conversation
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.
Thanks for your contribution. Kindly see above comments.
Also, commit message scope should be @schematics/angular
instead of @angular/cli
.
Hi @alan-agius4, thanks for reviewing this. I addressed your feedback. Should I also add a test? |
Sorry, I @alan-agius4, I overlooked your first comment in which you asked me to add a test. Can you please point me at an example test which tests a similar thing? |
@chrisguttandin, Yes please add a test. You can use this
|
Thanks for the pointer. I added a test. Please let me know if there is anything else that needs to be changed. |
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.
Thanks for your contribution.
LGTM.
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. |
…al application This change allows `inlineTemplate=false` and/or `inlineStyle=false` to be used with the `minimal` option when creating an application either by `ng new` or `ng generate application`. Closes angular#16988
I noticed that when creating a project with the
minimal
flag like thisnpx @angular/cli new my-demo --minimal true
it will create anapp.component.ts
with inline styles and inline templates. However when creating another component withng generate component another-component
it will have an external template and external styles.This pull request tries to fix this inconsistency by setting the
inlineTemplate
andinlineStyle
options when creating aminimal
project to make sure all generated components will have inlined styles and templates.Please let me know if there is anything that needs to be changed.