Flags SDK now evaluates flags 10x faster
By Steven Van ·
Bulk flag evaluation in Next.js and SvelteKit apps speeds up after upgrading the flags and @flags-sdk/vercel packages.
The Vercel Flags SDK and Vercel Flags now evaluate multiple feature flags in bulk about 10x faster, according to the documentation. The speedup comes from reducing microtask queue overhead and creating fewer promises, and it scales with the number of flags evaluated at once.
To get the improvement, replace calls like Promise.all([flagA(), flagB()]) with await evaluate([flagA, flagB]), or pass an object to evaluate flags under named keys. The precompute function benefits automatically, with no code changes needed. Upgrade the flags and @flags-sdk/vercel packages to the latest versions to use it.