vercel-flags
БесплатноБез исполняемых скриптовНе проверенFeature flags, A/B tests, and gradual rollouts with Vercel Flags, in any app or framework. Use whenever the user is planning, adding, changing, or cleaning up…
от vercel★ 356 звёзд на GitHubОб этом скилле
Vercel Flags
Vercel Flags is Vercel's feature flags platform. Flags are created and managed in the Vercel dashboard or with the vercel flags CLI, evaluated server-side in your app, and switched per environment (Development, Preview, Production) without a redeploy.
- Docs: https://vercel.com/docs/flags
- CLI reference: https://vercel.com/docs/cli/flags
Use this skill to decide how a feature should be flagged, to create and change flags, and to run rollouts and experiments. Write app code with the skill that matches the stack (see Choose an approach). Do not leave CLI steps as "next steps" for the user; execute them yourself.
Route the request
- Planning ("put this behind a flag", "roll this out to 10%", "A/B test the pricing page", "add a kill switch"): follow Plan a flag, then Choose an approach.
- Create or manage a flag with no code change (create, inspect, enable, set, split, rollout, rules, archive): follow Manage flags with the CLI. This needs an authenticated CLI, not SDK packages, Toolbar, Flags Explorer, or
.env.local(exceptvercel flags override, which readsFLAGS_SECRET). - Share flags between projects: follow Project Connections to connect projects in the same team, then configure the consumer application.
- Clean up or remove a flag ("remove this flag", "clean up stale flags", "inline this flag"): follow references/cleanup.md, then Lifecycle and safety before archiving.
- Add a flag to an app that already uses the Flags SDK (
flagsinpackage.json): load theflags-sdkskill right away; it creates the flag on Vercel and declares it in code. - Implement in code otherwise: follow Choose an approach and load the matching skill or reference. Inside an app repository, treat an ambiguous request as plan, create, and implement.
Choose an approach
Check the project before writing code.
- Already using another flag provider (Statsig, LaunchDarkly, PostHog, GrowthBook, and so on): keep it. On Next.js or SvelteKit, the Flags SDK connects to it through an adapter; load the
flags-sdkskill. On any other stack, use the provider's own SDK. Rollouts, targeting, and experiments for that provider are configured in its own dashboard, not withvercel flags; the CLI and lifecycle sections of this skill do not apply. - No provider yet: use Vercel Flags. Pick the integration by stack (SDKs):
- Next.js or SvelteKit: the Flags SDK (
flags+@flags-sdk/vercel). It adds Flags Explorer integration and precompute for static pages. Load theflags-sdkskill. If it is not available, suggestnpx skills add vercel/flags@flags-sdk(do not auto-install). - Any other framework or a plain server (for example Express):
@vercel/flags-core. See Other frameworks. - The user wants provider portability or already uses OpenFeature: the Vercel Flags OpenFeature provider (Using OpenFeature with Vercel Flags).
- Next.js or SvelteKit: the Flags SDK (
The dashboard and the vercel flags CLI work the same for every integration.
Plan a flag
Decide these before creating the flag; the kind cannot be changed later.
- Kind:
booleanfor on/off and kill switches;string,number, orjsonwhen the flag selects a variant or carries configuration (Flag types). - Variants: name them after the behavior (
control,new-checkout), not after the rollout step. - Key: kebab-case, stable, and the same string in the CLI, the dashboard, and the code (
keyinflag()or the first argument ofevaluate()). - Environments: each environment serves its own value or targeting. Plan what Development, Preview, and Production serve at launch.
- Targeting: a percentage rollout or A/B split needs a stable identity to bucket by, such as
user.id. Define the entity and attribute under Flags → Entities first; the app must return the same names from its evaluation context (Entities). - Fallback: the value the app serves when the flag is archived, not yet created, or evaluation fails. This becomes
defaultValuein code. - Exit: a flag is temporary unless it is a long-lived operational switch. Plan the removal order in references/cli.md — Lifecycle and safety.
Manage flags with the CLI
The CLI uses your Vercel account authentication. SDK keys and vercel env pull are application credentials, not CLI prerequisites.
Prerequisite: The Vercel CLI must be installed and authenticated. If it is not installed, run
pnpm i -g vercel. For auth
Установить vercel-flags в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл vercel-flags?
Feature flags, A/B tests, and gradual rollouts with Vercel Flags, in any app or framework. Use whenever the user is planning, adding, changing, or cleaning up a feature flag, toggle, kill switch, experiment, percentage rollout, or targeting rule, or wants to gate or hide a feature for some users, even before a library or provider is chosen. Covers choosing an integration (Flags SDK, `@vercel/flags-core`, OpenFeature), the Vercel dashboard, the `vercel flags` CLI (create, inspect, set, split, rollout, rules, segments, evaluations, archive, connections), Project Connections, OIDC vs SDK keys, `FLAGS_SECRET`, and Flags Explorer overrides. For `flag()` declarations, adapters, precompute, and the Flags Explorer endpoint in Next.js or SvelteKit code, load the `flags-sdk` skill.
Как установить скилл vercel-flags?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл vercel-flags запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic