Contributing to Isekai
Thank you for your interest in contributing! Isekai Core is a monorepo built with pnpm workspaces. This guide will help you set up your development environment.
Prerequisites
Section titled “Prerequisites”- Node.js: Version 20+
- pnpm: Version 9+ (
npm install -g pnpm) - Docker: Required for running the local database and Redis.
Project Structure
Section titled “Project Structure”We use a monorepo structure to share code between the API and the Worker.
Directoryapps/
Directoryisekai-frontend/ React / Vite. The user interface.
- …
Directoryisekai-backend/ Express API. Handles auth, database access, and job scheduling.
- …
Directoryisekai-publisher/ Background Worker. Processes queues (uploading to DA, S3 cleanup).
- …
Directorypackages/
Directoryshared/ Shared Library. Contains Prisma schema, database client, and shared types.
- …
Local Setup
Section titled “Local Setup”-
Clone & Install
Terminal window git clone https://github.com/isekai-sh/isekai-core.gitcd isekai-corepnpm install -
Start Infrastructure
We provide a
docker-compose.local.ymlto spin up just the dependencies (Postgres & Redis) without the apps.Terminal window docker-compose -f docker-compose.yml up -d postgres redis -
Environment Variables
You need to set up
.envfiles for each workspace. We have a helper script, or you can copy them manually:Terminal window cp apps/isekai-backend/.env.example apps/isekai-backend/.envcp apps/isekai-frontend/.env.example apps/isekai-frontend/.envcp apps/isekai-publisher/.env.example apps/isekai-publisher/.envcp packages/shared/.env.example packages/shared/.env -
Database Setup
Push the schema to your local Docker Postgres instance:
Terminal window pnpm db:migrate -
Start Development Servers
This command starts the Frontend, Backend, and Publisher in parallel with hot-reloading.
Terminal window pnpm devThe app will be available at http://localhost:3000.
Common Commands
Section titled “Common Commands”pnpm build: Build all apps and packages.pnpm lint: Run ESLint across the monorepo.pnpm test: Run Vitest unit tests.pnpm db:studio: Open Prisma Studio to view/edit database records manually.