跳到正文
Vercel Blog(vercel.com)· Andy Schneider·· 剛剛品質評分54

Vercel Flags 可在功能旗標缺漏時擋下正式部署

Catch missing feature flags before they reach production

重點導讀

程式碼裡寫了功能旗標,專案卻還沒建立對應設定時,應用程式可能會直接使用預設值,意外開啟原本想關閉的功能。

  • Vercel Flags 新增部署檢查,部署準備完成時會找出缺少的旗標並列出名稱,團隊建立好設定後就能重新部署。
  • 要啟用這項檢查,專案環境中必須設定 FLAGS_SECRET,並在 Build and Deployment 設定裡開啟檢查、將它設為必要條件。

AI 伴隨問答

自備 Key 深度分析

針對這篇報導有疑問?可直接點選快捷問題或向 AI 追問背景脈絡與技術細節:

正文

# Catch missing feature flags before they reach production - Vercel
Skip to content

[](https://vercel.com/home)

Copy Wordmark Copy Logo

Download Brand Assets Brand Guidelines

Products

Agent Stack

Core Platform

Tools

Resources

Learn

Build

Explore

EnterprisePricing

Get a DemoLog InSign Up

Ask AIDashboard

Image 1

  • * *

Products

Agent Stack

Core Platform

Tools

Resources

Learn

Build

Explore

Enterprise

Pricing

Get a Demo

Log InSign Up

Catch missing feature flags before they reach production

Image 2Image 3

Andy Schneider, Dominik Ferber

BlogChangelog

23 Nov 2026

1 min read

Copy

Vercel Flags can now block a deployment from reaching production if you’ve declared a flag in code but haven’t created it in your project. Without that definition, your app can silently fall back to the flag’s default value, even if that turns on a feature you meant to keep off.

The Flag Definitions PresentDeployment Check runs when a deployment is ready. If any flags are missing, the check fails and lists them in the results, where you can create each one before redeploying.

The check reads your Flags SDK discovery endpoint and requires FLAGS_SECRET to be set in your project’s environment.

To turn on blocking, teams on all plans can enable the check in their project’s Build and Deployment settings and mark it as required. See the Deployment Checks documentation for setup details.

Agent Stack

Core Platform

Security

Tools

Frameworks

SDKs

Build

Learn

Explore

Company

Legal & Trust

Social

  • Image 4: VercelImage 5: Vercel

Loading status…

Select a display theme:system light dark

來源: Vercel Blog (vercel.com)
開啟原文

讀者討論

理性交流 · 即時討論