2020-07-04 16:04:30 +08:00
|
|
|
## 开发
|
2019-10-08 09:14:38 +08:00
|
|
|
|
|
|
|
```bash
|
2020-07-04 16:04:30 +08:00
|
|
|
# 克隆项目
|
2019-10-08 09:14:38 +08:00
|
|
|
git clone https://gitee.com/y_project/RuoYi-Vue
|
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
# 进入项目目录
|
2019-10-08 09:14:38 +08:00
|
|
|
cd ruoyi-ui
|
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
# 安装依赖
|
2019-10-08 09:14:38 +08:00
|
|
|
npm install
|
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
# 建议不要直接使用 cnpm 安装依赖,会有各种诡异的 bug。可以通过如下操作解决 npm 下载速度慢的问题
|
2022-03-30 10:39:09 +08:00
|
|
|
npm install --registry=https://registry.npmmirror.com
|
2019-10-08 09:14:38 +08:00
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
# 启动服务
|
2019-10-08 09:14:38 +08:00
|
|
|
npm run dev
|
|
|
|
```
|
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
浏览器访问 http://localhost:80
|
2019-10-08 09:14:38 +08:00
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
## 发布
|
2019-10-08 09:14:38 +08:00
|
|
|
|
|
|
|
```bash
|
2020-07-04 16:04:30 +08:00
|
|
|
# 构建测试环境
|
2019-10-08 09:14:38 +08:00
|
|
|
npm run build:stage
|
|
|
|
|
2020-07-04 16:04:30 +08:00
|
|
|
# 构建生产环境
|
2019-10-08 09:14:38 +08:00
|
|
|
npm run build:prod
|
|
|
|
```
|