Skip to content

Commit faf8db7

Browse files
authored
Merge pull request #53 from OwnderDuck/main
Update base config for deployment and add Chinese deployment guide
2 parents 75833b1 + 0f18a1a commit faf8db7

2 files changed

Lines changed: 14 additions & 2 deletions

File tree

README_zh.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
简体中文 | <a href="README.md">English</a>
55
</p>
66

7-
这是一个受 [CS Academy 图形编辑器](https://csacademy.com/app/graph_editor/) 启发的图形编辑器,专为竞赛编程设计
7+
这是一个受 [CS Academy 图形编辑器](https://csacademy.com/app/graph_editor/) 启发的图形编辑器,专为 OI 设计
88

99
使用 React、Typescript、Tailwind CSS 和 HTML Canvas 构建。
1010

@@ -188,6 +188,18 @@
188188

189189
除了暗黑/亮色主题,还有多个滑块可以调整节点半径、字体大小等参数。你的设置会在刷新后保存在 `localStorage` 中。
190190

191+
## 部署
192+
- 下载本项目
193+
- 切换到项目根目录
194+
- (可选)默认部署路径为 `/another_graph_editor/`。如果需要可以到 `vite.config.ts` 中修改 `base: "/another_graph_editor/"` 为其他的。
195+
- 安装依赖并构建:
196+
```bash
197+
npm install
198+
npm run build
199+
```
200+
- 构建产物会生成在:`dist/`
201+
202+
191203
## 致谢
192204

193205
- [CS Academy 的 Graph Editor](https://csacademy.com/app/graph_editor/)

vite.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,5 @@ export default defineConfig({
1313
},
1414
}),
1515
],
16-
base: "https://anacc22.github.io/another_graph_editor/",
16+
base: "/another_graph_editor/",
1717
});

0 commit comments

Comments
 (0)