你可以在这里查看简体中文版的「说明书」: README-CN
Hello there!
This project is the backend part of the visual novel game "HelloVN". It is developed using Node.js and primarily uses the Koa library to implement APIs, and the Sequelize library to communicate with the database (MySQL).
Due to my limited technical skills during the development of this project, the code may contain:
- Messy file structure
- Ugly code
- Bugs galore
- ......
It is recommended to use pnpm as the package manager.
First, clone this project:
$ git clone https://github.com/HelloVNProject/Backend ./HelloVN-Backend
$ cd ./HelloVN-BackendThen, create two configuration files config.ts and db.config.ts inside the app/config directory:
// Example config.ts
// Modify according to your actual situation
module.exports = {
privateKey: "", // key required for jwt
cookie: "", // Teambition API Cookie (currently not in use)
spaceCookie: "" // Space API Cookie
}// Example db.config.ts
// Modify according to your actual situation
module.exports = {
HOST: "", // MySQL domain
USER: "",
PASSWORD: "",
DB: "hellovn",
port: 3306,
dialect: "mysql",
pool: {
max: 5,
min: 0,
acquire: 30000,
idle: 10000
}
};After creating and modifying the files, use the following commands to run:
$ pnpm install
$ pnpm startPlease note that by default it runs on port 14514. You can modify it in main.ts if needed.