userId).
Install
Inline catalog
Predicates
Multiple predicates AND together within a
when block. Multiple rules within a flag’s targeting array fire in order; first match wins.
Bucketing
hashBucket(key, percent) is FNV-1a. It is fast (sub-microsecond per call), well-distributed, and deterministic. PostHog and LaunchDarkly use the same hash for local-eval.
For per-tenant rollouts (every member of a tenant sees the same value), set rollout.key = "orgId". For cohort experiments, supply a custom property key.
SSR bootstrap
evaluateAll(flags, ctx) resolves every flag’s current value. Serialize the result into the SSR-rendered HTML. The client then does not wait for a flag fetch. This removes the “flicker” where a flag-controlled UI flashes before the eval completes.
Editable flags
Whencfg.editable === true, the manifest fragment adds a FeatureFlag entity plus setFlag / deleteFlag admin mutations. The runtime caches the catalog in-process and invalidates on mutation. Use this for a switch ops must change without a redeploy.