0
윈도우 10에 설치 package.json 데이터가 내가 노드 v6.10.3 및는 NPM 동안
는이 문제를 해결하는 데 도움이 바랍니다 NPM의 v3.10.10을 사용하고이 오류 를 얻고 분석하는 데 실패 받고 설치합니다. 내가
npm ERR! npm v3.10.10
npm ERR! file C:\angular2-helloworld\package.json
npm ERR! code EJSONPARSE
npm ERR! Failed to parse json
npm ERR! Unexpected token '\r' at 5:71
npm ERR! "start": "tsc && concurrently \"npm run tsc:w\" \"npm run
lite\"\
npm ERR!
^
npm ERR! File: C:\angular2-helloworld\package.json
npm ERR! Failed to parse package.json data.
npm ERR! package.json must be actual JSON, not just JavaScript.
npm ERR!
npm ERR! This is not a bug in npm.
npm ERR! Tell the package author to fix their package.json file.
JSON.parsenpm ERR! node v6.10.3
package.json 파일 내용을 얻고있다
오류 : 그 문자가 JSON을 나누기
"start":"tsc && concurrently \"npm run tsc:w\" \"npm run lite\" ",
:
{
"name":"angular2-helloworld",
"version":"1.0.0",
"scripts":{
"start":"tsc && concurrently \"npm run tsc:w\" \"npm run lite\" ",
"tsc":"tsc",
"tsc:w":"tsc -w",
"lite":"lite-server",
"typings":"typings",
"postinstall":"typings install"
},
"license":"ISC",
"dependencies":{
"angular2":"2.0.0-beta.14",
"systemjs":"0.19.25",
"es6-shim":"^0.35.0",
"reflect-metadata":"0.1.2",
"rxjs":"5.0.0-beta.2",
"zone.js":"0.6.6"
},
"devDependencies":{
"concurrently":"^2.0.0",
"lite-server":"^2.2.0",
"typescript":"^1.8.9",
"typings":"^0.7.12"
}
}
어떤 tsc 작업을하나요? 또한 시작 스크립트에서'npm run '없이 tsc를 시작하는 이유는'tpm : w'를'npm run tsc : w'로 시작하는 이유입니까? –
'\ r '은 캐리지 리턴을 의미합니다. NPM은 5 행 끝 부분에서 캐리지 리턴에 대해 불평하고 있습니다.'package.json'을 변경하기 위해 사용하는 텍스트 편집기는 무엇입니까? –
메모장을 변경하려면 ++를 사용하고 있습니다. –