安装
# 环境支持
由于 Vue 3 不再支持 IE11,RuleGo-Editor 也不再支持 IE 浏览器。
| Edge ≥ 79 | Firefox ≥ 78 | Chrome ≥ 64 | Safari ≥ 12 |
|---|
# 编译
RuleGo-Editor 使用Vite (opens new window) 进行打包。你可以选择一个你喜欢的包管理器,以下例子使用npm(先安装nodejs (opens new window))
安装:
进入到项目目录,执行以下命令:
npm install
1
dev:
npm run dev
1
build:
npm run build
1
# 部署到 RuleGo-Server
构建产物默认输出到 dist/ 目录。将 dist/ 目录下的所有文件复制到 RuleGo-Server 的 editor/ 目录即可:
your-app/
├── server # 服务端二进制
├── config.conf # 配置文件
└── editor/ # 构建产物(原 dist/ 内容)
├── index.html
├── config/
└── assets/
1
2
3
4
5
6
7
2
3
4
5
6
7
确保 config.conf 中 resource_mapping 配置正确:
resource_mapping = /editor/*filepath=./editor,/images/*filepath=./editor/images
1
启动 server 后访问 http://localhost:9090/ 即可使用编辑器。
# 集成注意事项
如果编辑器需要集成到 RuleGo-Server,确保 vite.config.js (opens new window) 中 base 配置为 /editor/:
export default defineConfig({
base: '/editor/',
// ...
})
1
2
3
4
2
3
4
如果是独立部署或嵌入到其他系统,根据实际路径修改 base 配置。
上次更新: 2026/05/29, 04:08:46