Hypertune with Vercel Edge Config

This example shows how to use the Hypertune integration with Edge Config.

Server-side feature flag: true

Client-side feature flag: false

Once you've deployed this project, open the Hypertune console and try updating your feature flag logic.

To develop your project locally:

  • Clone your project's repository and cd into it
  • Run vercel link to link to the Vercel project
  • Run vercel env pull .env.development.local to pull your environment variables
  • Copy the NEXT_PUBLIC_HYPERTUNE_TOKEN variable from.env.development.local to .env
  • Run npm i
  • Run npm run dev

This example assumes your Hypertune project has an exampleFlag feature flag defined on the root field in your project schema. If you created a new Hypertune project while installing the integration, it will have this feature flag by default. But if you connected an existing Hypertune project without this example flag, follow the instructions below:

To add new feature flags, define them in your project schema and configure their logic in the Hypertune console. Then add them to hypertune.graphql and run npx hypertune to generate type-safe methods for them which you can use in your app.