简体   繁体   中英

ng serve Unable to find “@angular/cli” in devDependencies

$ ng serve Unable to find "@angular/cli" in devDependencies.

Please take the following steps to avoid issues: "npm install --save-dev @angular/cli@latest" You seem to not be depending on "@angular/core". This is an error.

in the backend(symfony) is run corretly but I had this error in angular js frontend when i want to run my server can someone have a idea why and how i solve

This may happen if you aren't in you root directory of your application. This can happen if you created a new project with the command ng new project-name and then try to run serve command without actually entering the created project directory.
1. Create a new project $ ng new project-name
2. Enter the project directory $ cd project-name
3. Only now run $ ng serve

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM