我正在尝试将npm软件包依赖项安装到我的angular应用程序中,并且出现此错误。有任何解决方法吗?
npm ERR! code E404
npm ERR! 404 Not Found: error-ex@^1.2.0
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Dilushi\AppData\Roaming\npm-cache\_logs\2020-02-12T13_07_17_602Z-debug.log
我将在此处附加我的package.json
文件。
{
"name": "app-pfe",
"version": "0.0.1",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.2",
"@angular/common": "^6.0.2",
"@angular/compiler": "^6.0.2",
"@angular/core": "^6.0.2",
"@angular/forms": "^6.0.2",
"@angular/http": "^6.0.2",
"@angular/platform-browser": "^6.0.2",
"@angular/platform-browser-dynamic": "^6.0.2",
"@angular/router": "^6.0.2",
"@ng-dynamic-forms/core": "^6.0.6",
"@ng-select/ng-select": "^2.18.0",
"angular-webstorage-service": "^1.0.2",
"angular2-moment": "^1.9.0",
"core-js": "^2.5.4",
"inspector": "^0.5.0",
"jsrsasign": "^8.0.12",
"ngx-auth": "^5.0.0",
"ngx-bootstrap": "^5.0.0",
"node-sass": "^4.11.0",
"rxjs": "6.3.3",
"rxjs-compat": "6.3.3",
"underscore": "^1.9.1",
"zone.js": "^0.8.26"
},
"devDependencies": {
"@angular-devkit/build-angular": "^0.13.8",
"@angular-devkit/build-ng-packagr": "~0.6.8",
"@angular/cli": "~6.0.2",
"@angular/compiler-cli": "^7.2.14",
"@angular/language-service": "^6.0.2",
"@types/jasmine": "~2.8.6",
"@types/jasminewd2": "~2.0.3",
"@types/node": "~8.9.4",
"codelyzer": "~4.2.1",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "^4.0.1",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~1.4.2",
"karma-jasmine": "~1.1.1",
"karma-jasmine-html-reporter": "^0.2.2",
"ng-packagr": "^5.1.0",
"protractor": "^5.4.1",
"ts-node": "~5.0.1",
"tsickle": ">=0.25.5",
"tslib": "^1.7.1",
"tslint": "~5.9.1",
"typescript": "3.1.1"
}
}
答案 0 :(得分:15)
正如您在https://status.npmjs.org
上所看到的那样,目前有4个软件包被关闭。
他们已经解决了该问题,但是我们需要等待CDN世界的传播。
请勿更新您的软件包或安装新软件包以解决此问题。
编辑:世界标准时间14:34在欧洲尚不能使用
答案 1 :(得分:1)
尝试使用此配置npm
npm config set registry https://skimdb.npmjs.com/registry
答案 2 :(得分:0)
现在应该可以使用了。他们已修复它。我已经尝试过并且可以工作了
答案 3 :(得分:0)
有时您的其他软件包可能与您将要通过npm安装的软件包不兼容
卸载并重新安装最新的Node
具有最新的NPM版本
答案 4 :(得分:0)
此问题可能还有另一个原因,请检查您的npm注册表配置是http://registry.npmjs.org/而不是http://registry.npmjs.org或https://registry.npmjs.org/
答案 5 :(得分:0)
答案 6 :(得分:0)
我认为你触发了错误的命令,请检查命令的拼写
npx react-native run-android
然后它会起作用。