Абсолютно новый для Angular Я пытаюсь создать новый проект (мой первый Angular проект), но безуспешно, я систематически получаю эту ошибку:
⠸ Installing packages...npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm ERR! Unexpected end of JSON input while parsing near '...2.3.1 || >=4.0.0-beta'
npm ERR! A complete log of this run can be found in:
npm ERR! /home/fpezzati/.npm/_logs/2020-03-15T11_33_00_358Z-debug.log
✖ Package install failed, see above.
The Schematic workflow failed. See above.
Npm версия 6.14.2
, версия узла 12.6.1 и Angular 9.0.6. Я уже пытался обновить @angular/cli
до последней версии. Что я делаю не так?
Обновление Вот команда, которую я использую для создания своего проекта:
fpezzati@oem-OMEN-by-HP-Laptop-15-ce0xx microfrontend (feature/team-gwt) $ ng new team-alpha
? Would you like to add Angular routing? No
? Which stylesheet format would you like to use? CSS
CREATE team-alpha/README.md (1026 bytes)
CREATE team-alpha/.editorconfig (246 bytes)
CREATE team-alpha/.gitignore (631 bytes)
CREATE team-alpha/angular.json (3599 bytes)
CREATE team-alpha/package.json (1287 bytes)
CREATE team-alpha/tsconfig.json (489 bytes)
CREATE team-alpha/tslint.json (1953 bytes)
CREATE team-alpha/browserslist (429 bytes)
CREATE team-alpha/karma.conf.js (1022 bytes)
CREATE team-alpha/tsconfig.app.json (210 bytes)
CREATE team-alpha/tsconfig.spec.json (270 bytes)
CREATE team-alpha/src/favicon.ico (948 bytes)
CREATE team-alpha/src/index.html (295 bytes)
CREATE team-alpha/src/main.ts (372 bytes)
CREATE team-alpha/src/polyfills.ts (2835 bytes)
CREATE team-alpha/src/styles.css (80 bytes)
CREATE team-alpha/src/test.ts (753 bytes)
CREATE team-alpha/src/assets/.gitkeep (0 bytes)
CREATE team-alpha/src/environments/environment.prod.ts (51 bytes)
CREATE team-alpha/src/environments/environment.ts (662 bytes)
CREATE team-alpha/src/app/app.module.ts (314 bytes)
CREATE team-alpha/src/app/app.component.css (0 bytes)
CREATE team-alpha/src/app/app.component.html (25723 bytes)
CREATE team-alpha/src/app/app.component.spec.ts (954 bytes)
CREATE team-alpha/src/app/app.component.ts (214 bytes)
CREATE team-alpha/e2e/protractor.conf.js (808 bytes)
CREATE team-alpha/e2e/tsconfig.json (214 bytes)
CREATE team-alpha/e2e/src/app.e2e-spec.ts (643 bytes)
CREATE team-alpha/e2e/src/app.po.ts (301 bytes)
⠴ Installing packages...npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm ERR! Unexpected end of JSON input while parsing near '...tkMw1KLAXCawu1JtqI\n5'
npm ERR! A complete log of this run can be found in:
npm ERR! /home/fpezzati/.npm/_logs/2020-03-15T12_41_21_714Z-debug.log
✖ Package install failed, see above.
The Schematic workflow failed. See above.
И это package.json
как результат не удалось ng new
:
{
"name": "team-alpha",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "~9.0.6",
"@angular/common": "~9.0.6",
"@angular/compiler": "~9.0.6",
"@angular/core": "~9.0.6",
"@angular/forms": "~9.0.6",
"@angular/platform-browser": "~9.0.6",
"@angular/platform-browser-dynamic": "~9.0.6",
"@angular/router": "~9.0.6",
"rxjs": "~6.5.4",
"tslib": "^1.10.0",
"zone.js": "~0.10.2"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.900.6",
"@angular/cli": "~9.0.6",
"@angular/compiler-cli": "~9.0.6",
"@angular/language-service": "~9.0.6",
"@types/node": "^12.11.1",
"@types/jasmine": "~3.5.0",
"@types/jasminewd2": "~2.0.3",
"codelyzer": "^5.1.2",
"jasmine-core": "~3.5.0",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~4.3.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage-istanbul-reporter": "~2.1.0",
"karma-jasmine": "~2.0.1",
"karma-jasmine-html-reporter": "^1.4.2",
"protractor": "~5.4.3",
"ts-node": "~8.3.0",
"tslint": "~5.18.0",
"typescript": "~3.7.5"
}
}