下载nodejs zip包并加载到环境变量

nodejs的版本最好使用12版,而不是最新版


npm install webpack -g
npm install -g yarn
yarn config set registry https://registry.npm.taobao.org

npm install -g cnpm --registry=https://registry.npm.taobao.org

 

接下来是vue-cli的安装,由于vue已经分出了2与3,这里采用本地安装

cd C:\eclipse\app\vue2

npm install vue-cli

系统变量里新建,将将%VUE2_BIN%添加到用户path中

VUE2_BIN

C:\eclipse\app\vue2\node_modules\.bin

 

项目初始化 

C:\eclipse\wks\vue>vue init webpack esql-ui
? Project name esql-ui
? Project description A Vue.js project
? Author tanpengfei
? Vue build standalone
? Install vue-router? Yes
? Use ESLint to lint your code? No
? Set up unit tests No
? Setup e2e tests with Nightwatch? No
? Should we run `npm install` for you after the project has been created? (recommended) yarn

 

 如果terminal没有识别到windows的环境变量,确定环境变量配置好后,重启一下IDE

 

 安装Python27,这是因为vue的一些安装包需要通过python27进行安装

默认安装路径是 C:\Python27\python.exe,不要修改这个默认路径,vue的包如果发生环境变量中没有时,会直接去这个路径中找

 

 

 

 



相关文章:

  • 2022-12-23
  • 2021-08-20
  • 2021-07-27
  • 2021-12-14
  • 2021-11-16
  • 2022-12-23
  • 2021-09-25
  • 2021-08-16
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-08-30
  • 2021-12-06
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案