Skip to content

Add flag to remove boilerplate HTML in the app.component.html #6653

Closed
@johnpapa

Description

@johnpapa

Bug Report or Feature Request (mark with an x)

[ x ] feature request

Versions.

@angular/cli: 1.1.1
node: 8.0.0
os: darwin x64
@angular/animations: 4.1.3
@angular/common: 4.1.3
@angular/compiler: 4.1.3
@angular/core: 4.1.3
@angular/forms: 4.1.3
@angular/http: 4.1.3
@angular/platform-browser: 4.1.3
@angular/platform-browser-dynamic: 4.1.3
@angular/router: 4.1.3
@angular/cli: 1.1.1
@angular/compiler-cli: 4.1.3
@angular/language-service: 4.1.3

Repro steps.

ng new foo

Desired functionality.

I like that the new CLI behavior adds some links for new users in the app.component.html. However, once a user has more experience with the CLI it would be helpful to be able to set a global setting to disable this for all future projects (or one off projects).

I propose a flag --welcome that defaults to true. When set to false this trims down the app.component.html to a minimal amount (possibly the <h3> and <router-outlet> for routing apps).

Then ng set defaults.welcome false and ng set defaults.welcome false --global could be used to disable it for more experienced user of the CLI.

Maybe this is something a community member to contribute, if the CLI team is open to it.

It's not a huge issue, but I still think it is worth it given the importance of not creating code that is not needed (see the new proposed --minimal flag).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions