Skip to content

Local development

Use this setup to work on Imprime itself. To simply run it, prefer Docker.

  • Node.js 18 or later, npm

  • A MongoDB — the quickest is Docker:

    Terminal window
    docker run -d --name imprime-mongo -p 27017:27017 mongo:7
  1. Clone and install

    Terminal window
    git clone https://github.com/RemiDufeu/imprime.io.git
    cd imprime.io
    npm install
  2. Configure — create .env at the repository root (it’s read by both the backend and Vite):

    .env
    MONGODB_URI=mongodb://localhost:27017/imprime
    BETTER_AUTH_SECRET=dev-secret-change-me
    PORT=3023
    PUBLIC_APP_URL=http://localhost:3023
    CORS_ORIGIN=http://localhost:5173
    VITE_API_URL=http://localhost:3023
  3. Build the shared packages (needed once, and after changing them):

    Terminal window
    npm run build:common && npm run build:sdk
  4. Start backend and frontend with hot reload:

    Terminal window
    npm run dev
Script What it does
npm run dev Backend (tsx watch) + frontend (Vite) together
npm run dev:backend Backend only
npm run dev:frontend Frontend only
npm run build Build all packages
npm run lint Lint all packages
npm run docker:build Build the Docker image
Path Contents
packages/backend/src/routes REST endpoints
packages/backend/src/mcp MCP server and tools
packages/backend/src/services Business logic, PDF rendering (ExportService), auth
packages/frontend/src/pages Editor, home, login, API keys pages
packages/frontend/src/store/editor Editor state (Zustand slices)
packages/common/src Shared types, fonts, rendering helpers

Issues and pull requests are welcome on GitHub. Check the roadmap for planned features, and open an issue to discuss larger changes before starting.