Skip to content

Sample Projects

The best way to see RocketFlag in action is to run a real app. These open-source samples show end-to-end integration you can clone, run, and adapt.

A minimal React + Vite + TypeScript app that initialises a RocketFlag client and conditionally renders UI based on a flag’s state.

Terminal window
git clone https://github.com/rocketflag/react-rocketflag.git
cd react-rocketflag
npm install
npm run dev

Open http://localhost:5173, set your own Flag ID in src/App.tsx, and toggle the flag in the console to watch the UI change.

Tip: This sample fetches flags with the core client and a manual useEffect. For new React apps we recommend the React SDK, which gives you a provider, the useFlag hook, and a declarative <Flag> component with built-in loading/error handling.

Whatever your stack, getting started is the same three steps:

  1. Create a flag in the console — see the Quick Start.
  2. Install the relevant SDK (Node, React, Go) or call the API directly.
  3. Read the flag’s enabled value and branch your code on it.

Using a language we don’t have an SDK for yet? The API is a single GET request — see the Quick Start for curl, JavaScript, Python, Ruby, and Go examples.