when i am trying to install npm install gulp -D in cmd prompt there many errors displaying - laravel

node verison:v12.4.0
npm verison:6.13.4
laravel:5.8
Build failed with error code: 1
npm WARN The package popper.js is included as both a dev and production depende
cy.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.7 (node_modules\fs
vents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents
1.2.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"
)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass#4.11.0 postinstall: node scripts/build.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass#4.11.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional lo
ging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\CLOUD TIMON\AppData\Roaming\npm-cache_logs\2019-12-31T05
00_45_654Z-debug.log

first try to clean npm cache with :
npm cache clean --force
then delete node_modules folder completely, then again run npm install.
that should solve the problem.

Related

unable to resolve dependency tree in react-redux

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: quora2.0#0.1.0
npm ERR! Found: react#18.2.0
npm ERR! node_modules/react
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^16.8.0 || ^17.0.0" from #material-ui/core#4.12.4
npm ERR! node_modules/#material-ui/core
npm ERR! #material-ui/core#"*" 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\Dell\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\Dell\AppData\Local\npm-cache_logs\2022-11-06T06_29_10_297Z-debug-0.log
PS D:\Projects\QuoraClone\quora2.0> npm i #material-ui/core
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: quora2.0#0.1.0
npm ERR! Found: react#18.2.0
npm ERR! node_modules/react
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^16.8.0 || ^17.0.0" from #material-ui/core#4.12.4
npm ERR! node_modules/#material-ui/core
npm ERR! #material-ui/core#"*" 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\Dell\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\Dell\AppData\Local\npm-cache_logs\2022-11-06T06_31_22_131Z-debug-0.log
PS D:\Projects\QuoraClone\quora2.0> npm config set legacy-peer-deps true
PS D:\Projects\QuoraClone\quora2.0> npm install
npm WARN deprecated stable#0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
npm WARN deprecated w3c-hr-time#1.0.2: Use your platform's native performance.now() and performance.timeOrigin.
npm WARN deprecated svgo#1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
expecting to get answers

Laravel 9 Install vue router for vue 2.6.12

I try installing vue router with run command "npm install vue-router" but then showing error like this:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: undefined#undefined
npm ERR! Found: vue#2.6.14
npm ERR! dev vue#"^2.6.12" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer vue#"^3.2.0" from vue-router#4.0.14
npm ERR! node_modules/vue-router
npm ERR! vue-router#"*" from the root project
npm ERR!
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\ACER\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\ACER\AppData\Local\npm-cache_logs\2022-03-20T12_19_15_072Z-debug-0.log
please help
I solved it by installing vue-router#3.
npm install vue-router#3 --save
You can just try this.
Because your vue is not the latest version, it gives this error.
Use previous versions of vue-router.
To access old versions of vue-router, use the versions tab
Example : npm i vue-router#3.5.3

Laravel8 npm run dev outputs: ERESOLVE unable to resolve dependency tree

Goal
Avoid error message.
I have been getting the following error message when I run the command npm run dev:
npm notice
npm notice New major version of npm available! 7.6.1 -> 8.1.4
npm notice Changelog: https://github.com/npm/cli/releases/tag/v8.1.4
npm notice Run npm install -g npm#8.1.4 to update!
npm notice
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! Found: acorn#7.4.1
npm ERR! node_modules/acorn
npm ERR! acorn#"^7.0.0" from acorn-node#1.8.2
npm ERR! node_modules/acorn-node
npm ERR! acorn-node#"^1.6.1" from detective#5.2.0
npm ERR! node_modules/detective
npm ERR! detective#"^5.2.0" from tailwindcss#2.2.19
npm ERR! node_modules/tailwindcss
npm ERR! dev tailwindcss#"^2.0.2" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peerOptional acorn#"^8.5.0" from terser#5.10.0
npm ERR! node_modules/terser
npm ERR! terser#"^5.9.0" from laravel-mix#6.0.39
npm ERR! node_modules/laravel-mix
npm ERR! dev laravel-mix#"^6.0.6" from the root project
npm ERR! terser#"^5.7.2" from terser-webpack-plugin#5.2.5
npm ERR! node_modules/terser-webpack-plugin
npm ERR! terser-webpack-plugin#"^5.2.4" from laravel-mix#6.0.39
npm ERR! node_modules/laravel-mix
npm ERR! dev laravel-mix#"^6.0.6" from the root project
npm ERR! 1 more (webpack)
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/ml/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/ml/.npm/_logs/2021-12-02T07_41_55_149Z-debug.log
Quick Solution:
I can avoid the problem / error message with the following command:
npm install --legacy-peer-deps.
Output:
npm WARN deprecated querystring#0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated uuid#3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
added 807 packages, and audited 808 packages in 12s
84 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
Question
What do I have to do to run npm install again without getting the error message?
I have the same issue too. I have fixed it using this line
npm i acorn --dev
then run again
npm install && install run dev
npm install npm#latest -g
then
npm install webpack-dev-server --save-dev
working for me
If you are using Laravel Homestead Package for any Vagrant Environment, then don't run the command inside the Vagrant Project Directory.
Go outside to the local directory of the project and run these commands.
image of commands inside vagrant
You should run these here::
image of commands outside vagrant

npm install error - SKIPPING OPTIONAL DEPENDENCY

I'm trying to follow an online course of laravel with laragon. I need to run the command npm install, but it marks an error and I don't know how to fix it.
I tried to modify the path but that did not work
C:\laragon\www\social>npm install
"CALL "C:\laragon\nodejs\\node.exe" "C:\laragon\nodejs\\node_modules\npm\bin\npm-cli.js" prefix -g" no se reconoce como un comando interno o externo,
programa o archivo por lotes ejecutable.
> node-sass#4.11.0 install C:\laragon\www\social\node_modules\node-sass
> node scripts/install.js
npm WARN ajv-keywords#3.2.0 requires a peer of ajv#^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN img-loader#3.0.1 requires a peer of imagemin#^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.7 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm ERR! file C:\Windows\system32\cmd.exe;C:\Users\Caribay\Anaconda3\Library\bin\graphviz;C:\Users\Caribay\AppData\Roaming\npm
npm ERR! path C:\Windows\system32\cmd.exe;C:\Users\Caribay\Anaconda3\Library\bin\graphviz;C:\Users\Caribay\AppData\Roaming\npm
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn C:\Windows\system32\cmd.exe;C:\Users\Caribay\Anaconda3\Library\bin\graphviz;C:\Users\Caribay\AppData\Roaming\npm
npm ERR! node-sass#4.11.0 install: `node scripts/install.js`
npm ERR! spawn C:\Windows\system32\cmd.exe;C:\Users\Caribay\Anaconda3\Library\bin\graphviz;C:\Users\Caribay\AppData\Roaming\npm ENOENT
npm ERR!
npm ERR! Failed at the node-sass#4.11.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Caribay\AppData\Roaming\npm-cache\_logs\2019-01-22T03_32_49_327Z-debug.log
I hope with this command works correctly but it marks these errors, help me, please
P.S: I work on a laptop with windows 7 home premium.
$ npm cache clean --force
delete node_modules by $ rm -rf node_modules
$ npm install
And then start it again with $ npm start
I think you should install manually ajv package or update it to version 6.0 if you already have a lower version
npm i ajv
i had a similar issue. after updating it works fine. Try doing same for other errors also.

npm install react-native-ibm-mobilefirst --save gives me error

react-native-ibm-mobilefirst#8.0.2018072413 postinstall D:\Call4Code\MyTestApp
\node_modules\react-native-ibm-mobilefirst
chmod +x scripts/postinstall.sh && ./scripts/postinstall.sh
'chmod' is not recognized as an internal or external command,
operable program or batch file.
npm WARN eslint-plugin-react-native#3.2.1 requires a peer of eslint#^3.17.0 || ^
4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.4 (node_modules\fse
vents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#
1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}
)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! react-native-ibm-mobilefirst#8.0.2018072413 postinstall: chmod +x scri
pts/postinstall.sh && ./scripts/postinstall.sh
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the react-native-ibm-mobilefirst#8.0.2018072413 postinstall s
cript.
npm ERR! This is probably not a problem with npm. There is likely additional log
ging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\shalvi_kubal\AppData\Roaming\npm-cache_logs\2018-08-16T10
_34_10_364Z-debug.log
Currently there is a workaround that I used to install the react-native-ibm-mobilefirst plugin. You can create your react native project from macOS and then install the react-native-ibm-mobilefirst plugin from there, and then copy that project folder from macOS to windows. Then run 'npm install' inside the project folder and it will work fine.

Resources