OpenLayers installation using npm - packet not found - npm

I am trying to install openlayers within my Express project using npm to create custom builds but I get the following error:
npm ERR! 404 Not Found
npm ERR! 404
npm ERR! 404 'mapbox/vector-tile' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it
npm ERR! 404 It was specified as a dependency of 'openlayers'
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, or http url, or git url.
npm ERR! System Linux 3.16.0-4-amd64
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "openlayers"
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.21
npm ERR! code E404
npm ERR!
npm ERR! not ok code 0
I tried updating npm and installing vector-tile manually but it didn't help.
What am I doing wrong?
EDIT: same error when calling npm install ol instead of npm install openlayers.

Use a more recent version of node and npm, preferably the LTS versions

Related

i am having npm error while trying to add sass to my vue project

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/vue-cli-plugin-sass-loader - Not found
npm ERR! 404
npm ERR! 404 'vue-cli-plugin-sass-loader#*' is not in
this registry.
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\hp\AppData\Local\npm-cache_logs\2023-01-28T23_47_26_128Z-debug-0.log
ERROR Error: command failed: npm install --loglevel error vue-cli-plugin-sass-loader -D --legacy-peer-deps
Error: command failed: npm install --loglevel error vue-cli-plugin-sass-loader -D --legacy-peer-deps
at ChildProcess. (C:\Users\hp\AppData\Roaming\npm\node_modules#vue\cli\lib\util\executeCommand.js:138:16)
at ChildProcess.emit (node:events:513:28)
at cp.emit (C:\Users\hp\AppData\Roaming\npm\node_modules#vue\cli\node_modules\cross-spawn\lib\enoent.js:34:29)
at maybeClose (node:internal/child_process:1098:16) at ChildProcess._handle.onexit (node:internal/child_process:304:5)
I tried npm install to get a new lock. JSON file and node module, but when I tried to run npm install, I still get huge npm errors, so that means I can't do npm install in my cd project nor can I add a sass plugin

error when i upgrade expo cli to latest version

when I run sudo npm i -g expo-cli
I got this:
scar#scar-OS:~/Desktop/React-Native-Projects/Final Project/yum-yum-app$ sudo npm i -g expo-cli.
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/expo-cli. - Not found
npm ERR! 404
npm ERR! 404 'expo-cli.#*' is not in this registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2022-05-20T14_12_15_519Z-debug-0.log

Can't install expo-cli to use react-native

I'm new in react-native and tried to install expo-cli in windows 10 following the page of react-native, id used the command npm init expo-cli and I have that error:
npm ERR! code E404
npm ERR! 404
npm ERR! 404 'create-expo-cli#latest' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Miguelangel\AppData\Roaming\npm-cache\_logs\2020-06-24T11_01_08_933Z-debug.log
Install for [ 'create-expo-cli#latest' ] failed with code 1
There is no create-expo-cli package. It's just expo-cli.
npm install -g expo-cli

This command is not working : npm install --save-dev node--sass#4.7.2

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/node--sass - Notfound
npm ERR! 404
npm ERR! 404 'node--sass#4.7.2' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name
yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HARIKA\AppData\Roaming\npm-cache\_logs\2020-05-
27T19_25_06_044Z-debug.log
C:\Users\HARIKA\Desktop\bootstrapassign1\Bootstrap4\conFusion>node-v 'node-v'
is not recognized as an internal or external command,operable program or
batch file.
I am getting this above error while installing node-sass into my windows7 using the command npm install --save-dev node--sass#4.7.2.
Can anyone help me please? Thank you in advance.
You might try reading the error message that NPM is logging:
npm ERR! 404 Not Found - GET https://registry.npmjs.org/node--sass - Notfound
npm ERR! 404
npm ERR! 404 'node--sass#4.7.2' is not in the npm registry.
^^^^^^^^^^
You're trying to install a package named node--sass which doesn't exist in NPM, rather than the desired package, node-sass, which does exist in NPM.

sudo npm install -g mocha not working

I am just running a basic mocha install command and its throwing the error in the mac terminal, Please suggest seeing the logs what can i do to get this running, Really appreciate the help.
AUK03154:~ itrmg$ sudo npm install –g mocha
Password:
npm ERR! 404 404 Not Found: %E2%80%93g
npm ERR! 404
npm ERR! 404 '%E2%80%93g' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, or http url, or git url.
npm ERR! System Darwin 13.1.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "–g" "mocha"
npm ERR! cwd /Users/itrmg
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.14
npm ERR! code E404
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /Users/itrmg/npm-debug.log
npm ERR! not ok code 0
Thanks
Deepesh
If you decode %E2%80%93g, you get -g. Something is wrong with the - character in -g. I copied the – character from your question to get its character code:
'–'.charCodeAt(0)
8211
Then I typed the dash myself:
'-'.charCodeAt(0)
45
As you can see your dash has a different character code. If you copy this command, it should work:
npm install -g mocha
If you did a copy-paste of that command from another webpage/text-editor, there are some unwanted characters which get copied. Try typing the same command manually, the error should go away.