Cannot find module '/Users/dq212/node_modules/@schematics/angular/application'
Error: Cannot find module '/Users/dq212/node_modules/@schematics/angular/application'
at Function.Module._resolveFilename (module.js:469:15)
at Function.resolve (internal/module.js:27:19)
at new ExportStringRef (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/node_modules/@angular-devkit/schematics/tools/export-ref.js:15:32)
at NodeModulesEngineHost._resolveReferenceString (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/node_modules/@angular-devkit/schematics/tools/node-module-engine-host.js:61:21)
at NodeModulesEngineHost.createSchematicDescription (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/node_modules/@angular-devkit/schematics/tools/file-system-engine-host-base.js:151:34)
at SchematicEngine.createSchematic (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/node_modules/@angular-devkit/schematics/src/engine/engine.js:82:40)
at CollectionImpl.createSchematic (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/node_modules/@angular-devkit/schematics/src/engine/collection.js:11:29)
at Object.getSchematic (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/utilities/schematics.js:40:23)
at Class.run (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/tasks/schematic-get-options.js:12:40)
at Class.beforeRun (/usr/local/Cellar/angular-cli/1.4.6/libexec/lib/node_modules/@angular/cli/commands/new.js:90:31)
我安裝nvm
,node
,angular-cli
和typescript
。當我嘗試tyring使用角CLI:收到此錯誤
ng new projectName
我得到了上述錯誤。我對很多這些工具都很陌生,但是我確實花了很多時間去尋找這個錯誤,而沒有到達任何地方。任何幫助表示讚賞。
我在Mac Sierra
10.12.6
我認爲這意味着你很可能試圖在另一個項目中創建一個新項目。所以只需使用'cd ../'退出此目錄,然後'ng project' – EyoelD