3

It's quite possible that an angular project was accidentally created inside my home folder in mac osx. So every time I try and create a new project using the angular-cli I receive "You cannot use the new command inside an angular-cli project". I've deleted all associated files with scaffolded project but the error persists. Are there any underlying files that need to be deleted to resolve this error?

1

2 Answers 2

4

Somewhere in a parent directory is a Angular-Cli project or where an ng init was ran. You have do go up your file structure and find the node_modules folder and delete it along with any associated angular-cli generated files (tslint.json, src folder, protractor.conf.js, node_modules folder , README.md, angular-cli.json, e2e folder, karma.conf.js, package.json, .npm/ folder).

Sign up to request clarification or add additional context in comments.

Comments

0

I was trying to add new angular application my using CLI.But I had "package.json" node_modules inside the same folder where I am creating new application folder,after deleting this file and folder.it is working for me.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.