2017-04-06 1 views
1

저는 Angular2 및 @ Angular-Cli에서 새롭습니다. @ angular-cli를 다운로드하고 livereload와 함께 사용하려고하지만 작동하지 않습니다. 버전 1.4.2에서 다운 그레이드를 시도했지만 여전히 작동하지 않습니다.@ 앵귤러 클라이밍 라이브로드가 작동하지 않습니다.

나는이 오류가 :

ERROR in ./src/main.ts 
Module build failed: TypeError: Cannot read property 'newLine' of undefined 
    at Object.getNewLineCharacter (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/typescript/lib/typescript.js:9514:20) 
    at Object.createCompilerHost (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/typescript/lib/typescript.js:63770:26) 
    at Object.ngcLoader (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/@ngtools/webpack/src/loader.js:380:33) 
@ multi webpack-dev-server/client?http://localhost:4200 ./src/main.ts 

ERROR in ./src/polyfills.ts 
Module build failed: TypeError: Cannot read property 'newLine' of undefined 
    at Object.getNewLineCharacter (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/typescript/lib/typescript.js:9514:20) 
    at Object.createCompilerHost (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/typescript/lib/typescript.js:63770:26) 
    at Object.ngcLoader (/home/cesar/Repositorios/proyectoAlbum/client-albums/node_modules/@ngtools/webpack/src/loader.js:380:33) 
@ multi ./src/polyfills.ts 

이 내 버전입니다 @ 각도-CLI 및 노드

/\ _ __ __ _ _ _| | __ _ _ __ /___| | |_ _| 
/△ \ | '_ \/_` | | | | |/ _` | '__| | | | | | | 
/___ \| | | | (_| | |_| | | (_| | |  | |___| |___ | | 
/_/ \_\_| |_|\__, |\__,_|_|\__,_|_|  \____|_____|___| 
       |___/ 
@angular/cli: 1.0.0 
node: 6.10.2 
os: linux x64 
@angular/common: 4.0.1 
@angular/compiler: 4.0.1 
@angular/core: 4.0.1 
@angular/forms: 4.0.1 
@angular/http: 4.0.1 
@angular/platform-browser: 4.0.1 
@angular/platform-browser-dynamic: 4.0.1 
@angular/router: 4.0.1 
@angular/cli: 1.0.0 
@angular/compiler-cli: 4.0.1 

감사합니다!

답변

0

올바르게 업그레이드하지 않았습니다. NGtools 바인딩이 올바르게 설정되지 않았습니다. 또한 https://github.com/angular/angular-cli#updating-angular-cli


:

함께 NPM 3 이상으로, 노드 6.9.0 이상이 필요합니다

다음 단계를 따르십시오.

여기에서 최신 버전을 다운로드 할 수 있습니다. https://nodejs.org/en/. 제대로 작동하고 있습니다.