Git - Cloning Vue.js project and run - vue.js

I have cloned a project from a Git Repo into my Mac, It only has project files not the node modules.
In GIT : Readme.md says run npm install to setup the project.
When I run the npm install I get below error list, how do I get through it?
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: #vue/eslint-config-standard#6.1.0
npm ERR! Found: eslint-plugin-vue#8.7.1
npm ERR! node_modules/eslint-plugin-vue
npm ERR! dev eslint-plugin-vue#"^8.0.3" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint-plugin-vue#"^7.0.0" from #vue/eslint-config-standard#6.1.0
npm ERR! node_modules/#vue/eslint-config-standard
npm ERR! dev #vue/eslint-config-standard#"^6.1.0" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: eslint-plugin-vue#7.20.0
npm ERR! node_modules/eslint-plugin-vue
npm ERR! peer eslint-plugin-vue#"^7.0.0" from #vue/eslint-config-standard#6.1.0
npm ERR! node_modules/#vue/eslint-config-standard
npm ERR! dev #vue/eslint-config-standard#"^6.1.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.
npm ERR!
npm ERR! See /Users/dev/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/dev/.npm/_logs/2022-06-23T23_17_06_125Z-debug-0.log

This bug seems current, to reproduce it :
vue create hello-world
Vue CLI v5.0.8
...
npm install
and if you do : rm -rf node_modules then npm install you get error :
npm ERR! While resolving: #vue/eslint-config-standard#6.1.0
And no solution till now
thank you

What I did to get rid of the problem was removing the:
"eslint-plugin-vue": "^8.0.3",
line in the package.json file.
from the "devDependencies" section.
Then I did an
npm install
to download all the dependencies. And after that I downloaded the eslint Vue plugin seperatly with the Vue CLI.
vue add eslint
I don't know if this is the solution to the problem. I just wanted to help.

Related

Error (code ERESOLVE) when in trying to run the command "npm install" on console log

I'm on a college project where I got a project with angular and typescript, languages which I have difficulty and I'm having problems when trying to run the project
Why when in trying to run the command install
npm install
The console return to me:
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: sisgeo#1.0.0
npm ERR! Found: zone.js#0.8.29
npm ERR! node_modules/zone.js
npm ERR! zone.js#"^0.8.19" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer zone.js#"~0.9.1" from #angular/core#8.2.14
npm ERR! node_modules/#angular/core
npm ERR! #angular/core#"^8.2.1" from the root project
npm ERR! peer #angular/core#"8.2.14" from #angular/animations#8.2.14
npm ERR! node_modules/#angular/animations
npm ERR! #angular/animations#"^8.2.1" 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.
npm ERR!
npm ERR! See C:\Users\desou\AppData\Local\npm-cache\eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\desou\AppData\Local\npm-cache\_logs\2022-09-13T01_56_25_713Z-debug-0.log
You can take a look at this resource (the problem mainly deals with dependency conflicts):
Unable to resolve dependency tree error when installing npm packages

ERESOLVE unable to resolve dependency tree while installing Font Awesome

I am workin on a react native project and I tried installing Font Awesome "npm i --save #fortawesome/react-native-fontawesome #fortawesome/fontawesome-svg-core react-native-svg"
using but I got
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: homesick#1.0.0
npm ERR! Found: react#18.2.0
npm ERR! node_modules/react
npm ERR! react#"^18.2.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"18.0.0" from react-native#0.69.4
npm ERR! node_modules/react-native
npm ERR! react-native#"0.69.4" from the root project
npm ERR! peer react-native#">= 0.67" from #fortawesome/react-native-fontawesome#0.3.0
npm ERR! node_modules/#fortawesome/react-native-fontawesome
npm ERR! #fortawesome/react-native-fontawesome#"*" 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.
npm ERR!
npm ERR! See /Users/itaylador/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/itaylador/.npm/_logs/2022-08-15T22_50_28_934Z-debug-0.log
How can I solve this error?
I had the same issue recently. Tried a lot configurations but the only thing that worked for me was downgrade from react#18.2.0 to react#18.0.0 in the package.json
Some other guys here on stackoverflow gave the hint (if you have peer dependency conflicts) to open (on MacOS) /Users/YourUser/.npm folder and delete the folders _cacache, _logs, _npx
You can also try to delete node_modules folder and package-lock.json file at the end and re-install via "npm install"

Unable to install vue-property-decorator or vue-class-component, when created project using vite

I have created a Vue3 project using Vite. When Vite is used I am unable to install vue-property-decorator or vue-class-component. It says it is unable to resolve dependency tree. Errors are attached below:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: new-vite-project#0.0.0
npm ERR! Found: vue#3.2.32
npm ERR! node_modules/vue
npm ERR! vue#"^3.2.25" from the root project
npm ERR! peer vue#"*" from vue-property-decorator#9.1.2
npm ERR! node_modules/vue-property-decorator
npm ERR! vue-property-decorator#"*" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer vue#"^2.0.0" from vue-class-component#7.2.6
npm ERR! node_modules/vue-class-component
npm ERR! peer vue-class-component#"*" from vue-property-decorator#9.1.2
npm ERR! node_modules/vue-property-decorator
npm ERR! vue-property-decorator#"*" 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.
npm ERR!
npm ERR! See /home/zohaib/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/zohaib/.npm/_logs/2022-04-13T20_02_35_956Z-debug.log
vue-class-component still doesn't officially support Vue 3.
It has a Release Candidate (RC) version though, but it may not be ready for production.
See this comment: vue-class-component issue #406
To install it:
npm install vue-class-component#8.0.0-rc.1 vue-property-decorator#10.0.0-rc.3

Install Pinia with Quasar v2

I'm using Quasar v2, Vue 3 and I'm trying to install Pinia.
Whenever I try to run: npm install pinia or also npm install pinia#next,
it gives me this error:
code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: ui#0.0.1
npm ERR! Found: vue#3.1.5
npm ERR! node_modules/vue
npm ERR! vue#"3.1.5" from #quasar/app#3.0.4
npm ERR! node_modules/#quasar/app
npm ERR! dev #quasar/app#"^3.0.4" from the root project
npm ERR! peer vue#"3.1.5" from #vue/compiler-sfc#3.1.5
npm ERR! node_modules/#vue/compiler-sfc
npm ERR! #vue/compiler-sfc#"3.1.5" from #quasar/app#3.0.4
npm ERR! node_modules/#quasar/app
npm ERR! dev #quasar/app#"^3.0.4" from the root project
npm ERR! peerOptional #vue/compiler-sfc#"^3.0.8" from vue-loader#16.4.1
npm ERR! node_modules/vue-loader
npm ERR! vue-loader#"16.4.1" from #quasar/app#3.0.4
npm ERR! node_modules/#quasar/app
npm ERR! dev #quasar/app#"^3.0.4" from the root project
npm ERR! 5 more (#vue/server-renderer, #vue/test-utils, vue-i18n, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! pinia#"*" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: vue#2.6.14
npm ERR! node_modules/vue
npm ERR! peer vue#"^2.6.14 || ^3.2.0" from pinia#2.0.2
npm ERR! node_modules/pinia
npm ERR! pinia#"*" 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.
npm ERR!
npm ERR! See /home/gii/.npm/eresolve-report.txt for a full report.
Does anyone know how to make this work?
Moreover, since I'm using Typescript, is there a way to configure it already with it via this initial npm command?
You can install Pinia if you remove Vuex first.
Just delete Vuex from your package.json and then you are free to install Pinia.
Faced the same problem while installing pinia from npm having vuex configured in my vue3 app , after couple of try i uninstalled vuex and reinstalled pinia and then it worked fine
If you just want to get everything installed and are not concerned about possibly running incompatible versions: npm install --legacy-peer-deps.
Beyond that, your options get much more involved. You can try updating everything and cross your fingers that all the most up-to-date versions are compatible with each other. You can downgrade dependencies that require newer versions of peer dependencies. And so on.

React-navigation- dependencies (Error while install NPM navigation dependencies package installation)

when I install this package
1 . npm install #react-native-community/masked-view .
it shows error like this
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: Sample_pro#0.0.1
npm ERR! Found: react#17.0.1
npm ERR! node_modules/react
npm ERR! react#"17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^16.0" from #react-native-community/masked-view#0.1.10
npm ERR! node_modules/#react-native-community/masked-view
npm ERR! #react-native-community/masked-view#"*" 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.
npm ERR!
npm ERR! See C:\Users\HP\AppData\Local\npm-cache\eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HP\AppData\Local\npm-cache_logs\2021-04-21T03_52_51_024Z-debug.log
-----How should I solve this problem-----
Ther error message is telling you that
your proj is using react # 17.0.1 version while #react-native-community/masked-view 0.1.10 has a dependency of react # 16.
To solve it, you can choose one of the followings:
upgrade #react-native-community/masked-view to the latest package which is accepting react#16 and react#17
downgrade your root project's react version to 16
please remove package-lock.json file and try to install again hope it will work.