Skip to content

Getting Started

Initial Setup

Environment

Docker

It is required as Payload uses a PostgreSQL database. After installation run docker compose up -d and for the first usage seed the database.

Node.js

Instead of installing single version from the official site, we recommend using n (Mac-only) or nvm to manage Node.js versions.

After installation you just have to run n auto or nvm use.

pnpm

We use Corepack to manage package manager version. It comes built-in with Node.js, so you only need to run corepack enable the first time you setup the project.

Environment Variables

You only need to copy .env.example to .env.local. It will be enough to run most of the project features locally. If you work on a specific feature that requires additional variables, ask the team.

VS Code

While you can use any IDE, VS Code is recommended. The project comes with a set of recommended extensions and settings files that will configure them to make working with the codebase easier.

Base Commands

  • pnpm dev - run the project in development mode.
  • pnpm test - run the tests.
  • pnpm lint - run code quality checks.
  • pnpm storybook - run the Storybook.
  • pnpm docs:dev - run the documentation site locally.