标签:fss nodejs https tle 系统 use web taobao hub
由于本人使用的是mac系统,因此在vue.js 的环境搭建上遇到许许多多的坑。感谢 showonne、yubang 技术指导,最终成功解决。下面是个人的搭建过程,权当是做个笔记吧。
由于mac非常人性化的将bash内置于终端中,因此可以直接在终端中使用bash命令。
打开终端运行以下命令:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
为了避免使用brew命令经常出错的情况,所以采用手动安装
下载地址:https://nodejs.org/en/download/ (选择mac os)
sudo chmod -R 777 /usr/local/lib/node_modules/
npm install -g cnpm --registry=https://registry.npm.taobao.org
cnpm install webpack -g
npm install vue-cli -g
cd 目录路径
vue init webpack-simple 工程名字<工程名字不能用中文>
一定要从官方仓库安装,npm 服务器在国外所以这一步安装速度会很慢。
npm install (慎用)
cnpm install (慎用)
vue-router
和网络请求模块vue-resource
cnpm install vue-router vue-resource --save
npm run dev
标签:fss nodejs https tle 系统 use web taobao hub
原文地址:http://www.cnblogs.com/Leo_wl/p/6798591.html