1.在Visual Studio Code的后端运行yarn serve
报错: Error: Watching remote files is not supported
2.分析
是webpack-dev-server
出了问题,这是setupWatchStaticFeature函数在3.7.2和3.8.0之间发生了变化引起的问题
3.处理:
1 npm install webpack-dev-server@3.7.2 --save-dev
2.PowerShell中创建vue项目提示无法加载文件
创建Vue项目出错,提示vue : 无法加载文件C:UsersxxxAppDataRoaming pmvue.ps1,因为在此系统上禁止运行脚本。有关详细信息,请参阅 https:/go.microsoft.com/fwlink/?LinkID=135170
解决:
- 以管理员身份运行PowerShell
- 执行:get-ExecutionPolicy,如果显示Restricted,表示状态是禁止的
- 执行:set-ExecutionPolicy RemoteSigned
- 选择Y