用 Express 和 Vue3 搭建的 ChatGPT 演示网页
Go to file
练亮斌 63af4a8e97
fix: 防止中文输入法输入英文时触发提交
部分输入法支持中英文混输,输入过程中按空格选择中文,按回车把当前的英文直接上屏。

至少在Chrome浏览器中,会把输入法选英文词的回车作为keyup事件,导致未输入完成的句子被提交。改成监听keypress事件就没问题了。
其他浏览器未测试。
2023-02-11 23:51:09 +08:00
.vscode chore: editor config 2023-02-11 08:17:48 +08:00
docs chore: cover.png 2023-02-10 09:32:43 +08:00
public chore: initialize 2023-02-09 11:21:33 +08:00
service feat: 支持上下文联想 2023-02-11 15:20:58 +08:00
src fix: 防止中文输入法输入英文时触发提交 2023-02-11 23:51:09 +08:00
.editorconfig chore: initialize 2023-02-09 11:21:33 +08:00
.env feat: 删除多余的内容 2023-02-09 15:18:30 +08:00
.eslintignore chore: initialize 2023-02-09 11:21:33 +08:00
.eslintrc.cjs chore: initialize 2023-02-09 11:21:33 +08:00
.gitattributes chore: initialize 2023-02-09 11:21:33 +08:00
.gitignore chore: editor settings 2023-02-09 16:20:45 +08:00
.prettierrc.json chore: initialize 2023-02-09 11:21:33 +08:00
CHANGELOG.md chore: version 1.0.4 2023-02-11 15:38:44 +08:00
README.md chore: README.md 2023-02-09 16:48:21 +08:00
README.zh-CN.md chore: README.md 2023-02-09 16:48:21 +08:00
index.html pref: reduce code 2023-02-10 09:19:37 +08:00
license pref: 优化部份内容 2023-02-09 15:48:27 +08:00
package.json chore: release v1.0.4 2023-02-11 15:38:57 +08:00
pnpm-lock.yaml chore: update deps 2023-02-11 08:32:59 +08:00
postcss.config.js chore: initialize 2023-02-09 11:21:33 +08:00
tailwind.config.js chore: initialize 2023-02-09 11:21:33 +08:00
tsconfig.json pref: reduce code 2023-02-10 09:19:37 +08:00
vite.config.ts pref: reduce code 2023-02-10 09:19:37 +08:00

README.md

ChatGPT Web Bot

English | 中文

ChartGPT demo page built with express and vue3

cover

Usage

Make sure node >= 18

If pnpm is not installed

npm install pnpm -g

install node deps

pnpm install

Sign up for an OpenAI API key and store it in your environment.

# .env
OPENAI_API_KEY="Your Key"

Run service

pnpm run service

Run web

pnpm run dev

License

MIT © ChenZhaoYu