unable to resolve dependency tree error for creating new angular project

5

so today I wanted to create new Angular project using the command ng new <projectname> and I got this error:

npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: project-name@0.0.0
npm ERR! Found: jasmine-core@3.6.0
npm ERR! node_modules/jasmine-core
npm ERR!   dev jasmine-core@"~3.6.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer jasmine-core@">=3.7.1" from karma-jasmine-html-reporter@1.6.0
npm ERR! node_modules/karma-jasmine-html-reporter
npm ERR!   dev karma-jasmine-html-reporter@"^1.5.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.

I literally tried everything , I updated npm , installed Angular cli again , download and installed node again , npm audit and lot of other things but nothing happened. Also as you can see error told me to use command with --force , I tried but nothing happened , and with --legacy-peer-deps ,I get the error as unknown option. What is bothering me the most is that everything was working completely right last night and I changed nothing at all but suddenly I'm getting this error today.

Share
Improve this question
New contributor
Nima Soltan is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
1
  • having same issue :( – NoviceDeveloper May 7 at 22:47

Comments

Popular posts from this blog

Meaning of `{}` for return expression

Get current scroll position of ScrollView in React Native

flutter websocket connection issue