ERROR  Failed to compile with 2 errors                                                                         12:00:33

 error  in ./src/App.vue

Module build failed: Error: No parser and no file path given, couldn't infer a parser.
at normalize (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:7051:13)
at formatWithCursor (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:10370:12)
at C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:31115:15
at Object.format (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:31134:12)
at Object.module.exports (C:\Users\admin\Desktop\222\demo\node_modules\vue-loader\lib\template-compiler\index.js:80:23) @ ./src/App.vue 11:0-354
@ ./src/main.js
@ multi (webpack)-dev-server/client?http://localhost:8081 webpack/hot/dev-server ./src/main.js error in ./src/components/HelloWorld.vue Module build failed: Error: No parser and no file path given, couldn't infer a parser.
at normalize (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:7051:13)
at formatWithCursor (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:10370:12)
at C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:31115:15
at Object.format (C:\Users\admin\Desktop\222\demo\node_modules\prettier\index.js:31134:12)
at Object.module.exports (C:\Users\admin\Desktop\222\demo\node_modules\vue-loader\lib\template-compiler\index.js:80:23) @ ./src/components/HelloWorld.vue 11:0-366
@ ./src/router/index.js
@ ./src/main.js
@ multi (webpack)-dev-server/client?http://localhost:8081 webpack/hot/dev-server ./src/main.js

解决方法:

npm i prettier@~1.12.0

重新运行:

npm run dev

原因是prettier 更新到1.13.0导致的

欢迎加入大前端交流群!群号:277942610,VIP新群

最新文章

  1. 浅谈ajax
  2. 用matlab实现同一个序列重复N倍
  3. MySQL基础 - 如何系统地学习数据库?
  4. Spring-task-timer定时器
  5. TimePicker 和TimePickerDiag
  6. (2015年郑州轻工业学院ACM校赛题) A 彩票
  7. MySQL ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO
  8. ARM指令集中经常使用的存储和载入指令
  9. windows ORA-12560: TNS: 协议适配器错误
  10. wcf、web api、webservicer 之间的区别
  11. 反射+自定义注解---实现Excel数据列属性和JavaBean属性的自动映射
  12. vue菜鸟从业记:公司项目里如何进行前后端接口联调
  13. css3选择器和伪类
  14. Pycharm基本设置和插件安装
  15. maven pom.xml文件 仓库搜索服务
  16. ubuntu16.04安装opencv2.4.13
  17. http://wenku.baidu.com/view/26afdb8371fe910ef12df8ccRevit采用DWG和FBX两种格式导入3D max方法的总结
  18. Scala的Trait详解
  19. 转载别人的一篇关于git的文章
  20. linux服务器---代理认证

热门文章

  1. pywin32安装教程
  2. ubuntu16下安装openssh
  3. nginx优化php-fpm优化 压力测试达到每分150万访问量webbench网站压力
  4. gson格式化参数 对象转Map
  5. Jmeter+badboy压力测试总结
  6. jackson 字符串转对象
  7. Hadoop2.7.7_HA高可用部署
  8. Leetcode中sort排序遇到的一些问题
  9. sqlserver2017 SSAS配置远程访问不成功的问题
  10. Dockerfile的alpine时区设置