我试图在此之后更新角度CLI,但现在我无法运行我的应用程序。当我尝试运行命令ng serve时
,它给我这个错误:
Could not find the implementation for builder @angular-devkit/build-angular:dev-server
Error: Could not find the implementation for builder @angular-devkit/build-angular:dev-server
at WorkspaceNodeModulesArchitectHost.resolveBuilder (C:\Users\Lupus\Documents\full-stack-projects\financial-app-ui\node_modules\@angular\cli\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js:49:19)
at ServeCommand.initialize (C:\Users\Lupus\Documents\full-stack-projects\financial-app-ui\node_modules\@angular\cli\models\architect-command.js:135:55)
at process._tickCallback (internal/process/next_tick.js:68:7)
at Function.Module.runMain (internal/modules/cjs/loader.js:745:11)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
npm install --save-dev @angular-devkit/build-angular 手动安装 devkit
npm i --only=dev
:
npm install
ng update
npm update
什么都没用。运行< code>ng v会得到以下结果:
Angular CLI: 8.0.3
Node: 10.15.0
OS: win32 x64
Angular: 8.0.1
... animations, cdk, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router
Package Version
-----------------------------------------------------------
@angular-devkit/architect 0.13.9
@angular-devkit/build-angular 0.13.9
@angular-devkit/build-optimizer 0.13.9
@angular-devkit/build-webpack 0.13.9
@angular-devkit/core 7.3.9
@angular-devkit/schematics 8.0.3
@angular/cli 8.0.3
@ngtools/webpack 7.3.9
@schematics/angular 8.0.3
@schematics/update 0.800.3
rxjs 6.5.2
typescript 3.4.5
webpack 4.29.0
还有我的包裹。json是这样的:
{
"name": "financial-app-ui",
"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": "^8.0.1",
"@angular/cdk": "^8.0.1",
"@angular/common": "^8.0.1",
"@angular/compiler": "^8.0.1",
"@angular/core": "^8.0.1",
"@angular/forms": "^8.0.1",
"@angular/platform-browser": "^8.0.1",
"@angular/platform-browser-dynamic": "^8.0.1",
"@angular/router": "^8.0.1",
"core-js": "^2.6.9",
"font-awesome": "^4.7.0",
"primeicons": "^1.0.0",
"primeng": "^7.1.3",
"rxjs": "~6.5.2",
"tslib": "^1.10.0",
"zone.js": "~0.9.1"
},
"devDependencies": {
"@angular-devkit/build-angular": "^0.13.9",
"@angular/cli": "^8.0.3",
"@angular/compiler-cli": "^8.0.1",
"@angular/language-service": "^8.0.1",
"@types/jasmine": "~2.8.8",
"@types/jasminewd2": "~2.0.3",
"@types/node": "~8.9.4",
"codelyzer": "~4.5.0",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~4.0.0",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.1",
"karma-jasmine": "~1.1.2",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.4.0",
"ts-node": "~7.0.0",
"tslint": "~5.11.0",
"typescript": "~3.4.5"
}
}
有人有其他建议吗?
我也有同样的问题。只有两个命令解决了我的问题
npm uninstall @angular-devkit/build-angular
npm install --save-dev @angular-devkit/build-angular
//OR
npm install @angular-devkit/build-angular
如果这个不行。别担心。运行此命令。
ng update @angular/cli @angular/core --allow-dirty --force
通过使用以下命令解决了我的问题:
ng update @angular/cli @angular/core --allow-dirty --force
我通过重新安装build angular软件包实现了这一点。注意install命令上的“--save dev”标志:
npm uninstall @angular-devkit/build-angular
npm install --save-dev @angular-devkit/build-angular
我试图更新角CLI,但现在我不能运行我的应用程序。当我尝试运行命令时,会出现以下错误: 我已经尝试了我能找到的一切。 null null 有人有其他建议吗?
我试图安装ngb-tabset,我在角核心上遇到了一些错误,因此我运行了: 但后来我得到了一些其他的错误...为此我做了,然后又有几个错误。我做了: 然后我开始得到下面的错误。 发生了一个未处理的异常:找不到builder@angle-devkit/build-角: dev-server的实现,有关详细信息,请参阅"/tmp/ng-2tgkqg/angular-errors.log"。 我试着去做
使用npm,我遵循Angular CLI快速入门页面上的入门指导。 在创建并进入我的新项目“frontend”后,运行<code>ng serve--open<code>,出现以下错误: 类似的问题 我也删除了模块,清除了缓存,然后安装了一个也没有工作。 package.json: angular.json:
使用npm,我遵循Angular CLI快速入门页面上的入门说明。 角度CLI快速启动 在创建并进入我的新项目“前端”后,运行,出现以下错误: 我试过其他类似问题的建议,但没有效果。答案是运行npm安装--save dev@angular devkit/build angular。 类似问题 我还删除了模块,清除了缓存,然后安装了一个同样不起作用的模块。 package.json: angular
然后我开始得到下面的错误。 发生未处理的异常:找不到builder@Angulat-devkit/build-Angulator:dev-server的实现有关详细信息请参阅“/tmp/ng-2tgkqg/Angulat-errors.log”。 我试着做- Angular.json
更新到 Angular 6.0.1 后,我在 上收到以下错误: < code>ng update表示一切正常。删除< code>node_modules文件夹和全新的< code>npm安装也没有帮助。 我的项目基于ng2-admin(Angular4版本)。以下是我的package.json dependecies: 和我的angular.json: