文章目录
  1. 1. Build Setup
  2. 2. Build Setup

鉴于我将于2017年9月26日正式离职,为了接受我工作的新同事能够尽快接手我手上工作并顺利开展工作,我整理成书面形式便于查阅

1.教委web项目
git地址:http://192.168.1.231/mark/education2.0.git
该项目使用sass预编译语言,gulp定时任务工具,Browsersync浏览器同步测试工具
开发项目都在src目录下。
src/css目录一般都是生成的但介于历史原因(开始没用sass后来转为sass)为防止出错做了保留,建议开发不要做处理
样式文件全部都在scss目录下。
其他imgs和js目录均正常,ueditor为第三方插件
由于我是在后需过程中接手这个项目,整理了大部分页面到aaa.html
所以再项目启动后可以通过 http://localhost:3000/aaa.html 页面查看已存在的页面便于后面改写
项目校验规则之一为:http://192.168.1.231/mark/education2.0/issues/9 不过项目中可能使用另外一种方案详询陈奇

1
2
3
4
5
6
git clone http://192.168.1.231/mark/education2.0.git 
cd education2.0
yarn #使用yarn安装(建议)
# npm install #也可以使用npm
yarn run dev #启动项目 启动后会自动打开项目首页
# npm run dev

2.FDAH5(食药监H5项目)
http://192.168.1.231/zhuyangxing/fda-h5-front.git
VUE2.0 项目使用vuecli 工具生成目录结构
使用yarn对项目包进行管理
yarn信息

1
2
3
4
# 全局安装yarn
npm install yarn -g
# 安装后即可查看yarn版本号,正常显示即可继续构建
yarn -V

Build Setup

1
2
3
4
5
6
7
8
9
10
11
git clone http://192.168.1.231/zhuyangxing/fda-h5-front.git   
cd fda-h5-front
# install dependencies
# 在项目目录下使用如下命令安装依赖 需提前安装好nodeJS
yarn install
# 启动项目
# serve with hot reload at localhost:8080
yarn run dev
# 构建项目
# build for production with minification
yarn run build

前后端分离项目需要配置后端代理路径(可以在项目里配置你也可以适应nginx配置)

1
2
3
4
5
6
7
8
9
proxyTable: {
'/fda-h5': {
target: 'http://10.10.11.11:8085',
// target: 'http://127.0.0.1:10010',
pathRewrite: {
'^/fda-h5': '/fda-h5'
}
}
},

项目开发端口为8280 启动后可以在 http://127.0.0.1:8280 访问
页面使用的地图为高德地图,饿了么前端封装的vue-amap 具体地址 https://elemefe.github.io/vue-amap 更多信息可查看相关api

3.微信家长端H5
http://192.168.1.231/zhuyangxing/weixin-h5-front.git
也是一个VUE2.0 项目使用vuecli 工具生成目录结构
使用yarn对项目包进行管理
yarn信息
注意事项:http://192.168.1.231/zhuyangxing/fda-h5-front/issues/16

1
2
3
4
# 全局安装yarn
npm install yarn -g
# 安装后即可查看yarn版本号,正常显示即可继续构建
yarn -V

Build Setup

1
2
3
4
5
6
7
8
9
10
11
git clone http://192.168.1.231/zhuyangxing/weixin-h5-front.git   
cd weixin-h5-front
# install dependencies
# 在项目目录下使用如下命令安装依赖 需提前安装好nodeJS
yarn install
# 启动项目
# serve with hot reload at localhost:8080
yarn run dev
# 构建项目
# build for production with minification
yarn run build

前后端分离项目需要配置后端代理路径(可以在项目里配置你也可以适应nginx配置)

1
2
3
4
5
proxyTable: {
'/weixin-h5': {
target: 'http://10.10.11.171:8080'
}
},

项目开发端口为8180 启动后可以在 http://127.0.0.1:8180 访问

也可以使用本地mock数据

1
yarn run mock

所有测试数据均在mock文件夹下,由于没有完整api文档所以mock数据不完整如需调试还是连接后台数据进行调试。

所有页面均在src/components/page下
页面一般都为单页面文件 都已经包含tempalte script style 三部分
也有一些单独的样式在src/components/styles里便于其他需要的页面引入
一些通用组件在src/components/common文件夹下

文章目录
  1. 1. Build Setup
  2. 2. Build Setup