凌的博客

您现在的位置是: 首页 > 前端学习 > Vue > 

Vue

Vue 3.0 第一章 安装与初始化

2022-06-07 Vue 527
yarn init

yarn global add @vue/cli@next

vue upgrade --next

# chrome浏览器开发工具 Vue Devtools
git clone https://github.com/vuejs/vue-devtools.git
cd vue-devtools
yarn install
yarn run build

#报错 改变源
yarn config set registry https://registry.npmmirror.com --global
yarn config set disturl https://npmmirror.com/dist --global
#清理缓存
yarn cache clean

yarn install 卡在这个界面很久,解决办法:

22.png

创建一个.yarnrc文件在根目录

内容如下:

registry "https://registry.npm.taobao.org"
sass_binary_site "https://npm.taobao.org/mirrors/node-sass/"
phantomjs_cdnurl "http://cnpmjs.org/downloads"
electron_mirror "https://npm.taobao.org/mirrors/electron/"
sqlite3_binary_host_mirror "https://foxgis.oss-cn-shanghai.aliyuncs.com/"
profiler_binary_host_mirror "https://npm.taobao.org/mirrors/node-inspector/"
chromedriver_cdnurl "https://cdn.npm.taobao.org/dist/chromedriver"


创建第一个项目:
vue create "helloworld"

yarn serve


附:

中文yarn.png



文章评论

0条评论