ShiftFast Docs

Local Development

Day-to-day commands, the local database, code style, and adding dependencies.

For first-time setup, see Setup.

Commands

CommandWhat it does
pnpm devStart the dev server (Turbopack) at localhost:3000.
pnpm build / pnpm startProduction build, and run it locally.
pnpm checkTypecheck and lint. Run before committing.
pnpm formatFormat the codebase with Prettier.
pnpm test / pnpm test:e2eUnit / end-to-end tests — see Testing.
pnpm local:up / pnpm local:downStart / stop the local Postgres container.
pnpm db:generateGenerate a migration from schema changes.
pnpm db:migrateApply migrations to the database at DIRECT_URL.
pnpm db:studioBrowse and edit your data in Drizzle Studio.

While working on billing, keep stripe listen running in a second terminal — see Stripe Setup.

Local database

pnpm local:up starts Postgres 17 in Docker on port 5432, with a named volume so data survives restarts. To start over with an empty database:

docker compose -f docker-compose.local.yml down -v
pnpm local:up
pnpm db:migrate

Code style

ESLint and Prettier run through pnpm check and pnpm format. On top of Next.js's ESLint config, imports are sorted and unused imports flagged automatically, and Prettier sorts Tailwind classes.

The repo ships VS Code settings in .vscode/: open the folder, install the recommended extensions (Prettier, ESLint, Tailwind CSS IntelliSense) when prompted, and files are formatted and lint-fixed on save.

Dependencies

Use pnpm — the repo ships pnpm-lock.yaml, and npm or yarn would create a second, diverging lockfile.

pnpm add <package>     # runtime dependency
pnpm add -D <package>  # dev-only: tooling, types, test libraries

Adding a UI component

Components come from shadcn/ui, built on Base UI rather than Radix (components.json sets "style": "base-vega"). Add one with:

pnpm dlx shadcn@latest add <component>

Some third-party registries, such as @magicui, generate components that import Radix. If a new component's imports don't match the rest of src/components/ui/ (@base-ui/react), rewrite them rather than adding a second primitives library.

On this page