Quickstart
Get the monorepo running locally and understand the main developer workflow.
Quickstart
This repository is a Bun monorepo. The fastest way to understand OpenFlags is to run the main applications locally, then connect an app to the SDK.
Requirements
- Bun
- A local environment capable of running the server and dashboard
Install dependencies
bun installRun the main apps
bun run dev:serverIn a second terminal:
bun run dev:dashboardIf you want the docs app too:
bun run dev:docsWhat you get
- The server exposes the flag API and stores rollout data.
- The dashboard lets you manage projects, users, and feature flags.
- The docs site gives onboarding and product messaging in one place.
Typical flow
- Create or choose a project.
- Define a feature flag with a stable
snake_casekey. - Enable it for a subset of users or by rollout percentage.
- Use the SDK in your app to check the flag locally.
First integration example
import { createClient } from "@openflagsdev/js"
const flags = await createClient({
apiUrl: "http://localhost:4000",
project: "my-app",
userId: "user_123",
})
if (flags.isEnabled("new_checkout")) {
showNewCheckout()
}Continue with Concepts for the reasoning behind evaluation and rollout behavior.