2017-02-09 83 views
2

我正在使用angular-CLI for angular 2,用於運行我正在執行ng服務之後ng服務器獲取模塊生成失敗'無法讀取未定義的屬性newLine'錯誤我所有的角度2項目。Angular 2打字稿:無法讀取屬性newLine undefined

Module build failed: TypeError: Cannot read property 'newLine' of undefined 
at Object.getNewLineCharacter (C:\Users\timebound\angularJson\node_modules\typescript\lib\typescript.js:8062:20) 
at Object.createCompilerHost (C:\Users\timebound\angularJson\node_modules\typescript\lib\typescript.js:44978:26) 
at Object.ngcLoader (C:\Users\timebound\angularJson\node_modules\@ngtools\webpack\src\loader.js:329:31) 

@ multi webpack-dev-server/client? http://localhost:4300/ ./src/main.ts

我跟着angular cli issues,還是我不能夠解決,我是新來的角2,請幫我

+0

請嘗試來詳細說明你的問題。如果不具體,我們不能幫你。 –

+0

即使在遵循角度cli升級說明後也有同樣的問題,刪除我的應用程序中的node_modes文件夾解決了它.. –

+0

@ frant.hartm謝謝,我通過運行npm啓動而不是執行ng服務。 –

回答

6

變化從"angular-cli": "1.0.0-beta.28.3"的devDependencies到"@angular/cli": "1.0.0-beta.30"

+0

嗨,我試着用@latest安裝,仍然堅持在'28.3'你怎麼得到'.30'下載? http://stackoverflow.com/questions/42419964/module-build-failed-typeerror-cannot-read-property-newline-of-undefined –

相關問題