问答详情
源自:3-2 配置vue的jsx写法以及postcss

vue页面报错

"D:\\nodejs\\WebStorm 2018.1.4\\bin\\runnerw.exe" "C:\\Program Files\\node.exe" "C:\\Program Files\\node_modules\\npm\\bin\\npm-cli.js" run start --scripts-prepend-node-path=auto

npm ERR! file C:\\Users\\Administrator\\Desktop\\my-project\\package.json

npm ERR! code EJSONPARSE

npm ERR! Failed to parse json

npm ERR! Unexpected token / in JSON at position 0 while parsing near '//{

npm ERR! //"name": "my-p...'

npm ERR! File: C:\\Users\\Administrator\\Desktop\\my-project\\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! Tell the package author to fix their package.json file. JSON.parse


npm ERR! A complete log of this run can be found in:

npm ERR!     C:\\Users\\Administrator\\AppData\\Roaming\\npm-cache\\_logs\\2018-06-15T10_10_02_421Z-debug.log


Process finished with exit code 1


提问者:慕姐6156777 2018-06-13 19:01

个回答

  • 萧浮生
    2018-06-27 12:04:39

    Unexpected token / in JSON at position 0 while parsing near '//{//"name": "my-p...'


    注意文件的格式是否出错