Angular: ng new error when I create an angular project
The problem seems to be the _
in project_name
resulting in the following error:
Schematic input does not validate against the Schema: {"name":"project_name","version":"6.0.1","newProjectRoot":"projects","skipInstall":false,"linkCli":false,"skipGit":false,"commit":null}
Errors:
Data path ".name" should match format "html-selector".
Replace _
e.g. with -
.
Further readings:
- Error when creating new project with Angular-CLI 6.1.2
- Style Guide
If you are using the terminal of IntelliJ IDEA while there is a angular project already imported in the IDEA, it is the problem of the IDEA.So, open the command promt of your windows and create the project.
I did this and I was able to create the project.
Setting the working directory in IntelliJ's Karma task, to the Angular project's main directory, also fixes the problem.