![](https://img2022.cnblogs.com/blog/718318/202205/718318-20220526153957767-59498929.png)
用yarn安装会出现各种报错,正确的做法:
1、npm install --registry=https://registry.npmmirror.com
2、npm install
3、npm run dev
完美运行,报跨域问题,
4、改vue.config.js,连接后端服务
![](https://img2022.cnblogs.com/blog/718318/202205/718318-20220526154258659-1001286739.png)
5、重启,执行npm run dev
用yarn安装会出现各种报错,正确的做法:
1、npm install --registry=https://registry.npmmirror.com
2、npm install
3、npm run dev
完美运行,报跨域问题,
4、改vue.config.js,连接后端服务
5、重启,执行npm run dev