✨ [FFL-2596] Feature Flags tab — overrides (stacked PR 3 of 3) - #4912
✨ [FFL-2596] Feature Flags tab — overrides (stacked PR 3 of 3)#4912kellyw1806 wants to merge 1 commit into
Conversation
|
All contributors have signed the CLA ✍️ ✅ |
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: 74968df | Docs | Datadog PR Page | Give us feedback! |
f6766af to
5375214
Compare
17cca80 to
5b4061e
Compare
Bundles Sizes Evolution
|
|
I have read the CLA Document and I hereby sign the CLA |
5b4061e to
31f7bb0
Compare
5375214 to
bc5e1d9
Compare
31f7bb0 to
c9960d2
Compare
| // Contract shared with @datadog/openfeature-browser's DatadogDevtools wrapper. | ||
| // Keep these in sync with that package: the wrapper reads OVERRIDES_KEY once on | ||
| // initialize() and writes DEVTOOLS_MARKER_KEY when it is composed into the provider stack. | ||
| export const OVERRIDES_KEY = 'dd.dd_flag.overrides' |
There was a problem hiding this comment.
These keys are a contract with @datadog/openfeature-browser's DatadogDevtools wrapper so renaming them requires a coordinated change in that package, not a free rename.
| type: FlagOverrideType | ||
| // Any JSON value — objects/arrays are `object`; `null` is allowed (a flag/variant value can be | ||
| // null). The manual-entry form still rejects null via validateOverrideValue. | ||
| value: boolean | string | number | object | null |
There was a problem hiding this comment.
Widened the override value to allow null (a variant value can legitimately be null). The manual-entry form still rejects null via validateOverrideValue. Is this okay or should variant-click also block null?
|
|
||
| useEffect(() => { | ||
| refresh() | ||
| const id = setInterval(refresh, REFRESH_INTERVAL) |
There was a problem hiding this comment.
This polls the inspected page every 2s while the tab is mounted. Fine for a devtools panel IMO, but flagging in case prefer gating it on tab visibility.
bc5e1d9 to
2e87cbc
Compare
c9960d2 to
fc8bff4
Compare
2e87cbc to
7b347cd
Compare
fc8bff4 to
5d030ab
Compare
17d898b to
919073f
Compare
4af8227 to
7376fbf
Compare
d3669d4 to
bad0da0
Compare
7376fbf to
fb4faa6
Compare
bad0da0 to
683bd8b
Compare
fb4faa6 to
230ae07
Compare
683bd8b to
1f5d159
Compare
230ae07 to
673a2b1
Compare
1f5d159 to
37d6b9b
Compare
673a2b1 to
2f033a5
Compare
37d6b9b to
b1988f2
Compare
2f033a5 to
98058ac
Compare
b1988f2 to
c9cefb8
Compare
98058ac to
e55866f
Compare
c9cefb8 to
3ef64a4
Compare
e55866f to
322814a
Compare
3ef64a4 to
e97cfa9
Compare
322814a to
87a1c1a
Compare
e97cfa9 to
6692837
Compare
87a1c1a to
875de0b
Compare
cf6c4db to
4602c7f
Compare
875de0b to
2c6bb67
Compare
4602c7f to
3e072de
Compare
Builds on FFL-2597: adds the override engine (writes to the inspected page's localStorage via the DatadogDevtools contract), per-variant override buttons + revert on each catalog row, a manual override-by-key form, and clear-all / save-and-reload controls.
2c6bb67 to
4dcadc8
Compare
3e072de to
74968df
Compare
Motivation
Stacked on #4916 (catalog fetch). Allows users to create overrides for a flag's value (allows for switching between variables) locally and have it take effect on the inspected page.
Stack (review bottom-up)
mainffl-2597ffl-2858Changes
useFlagOverrides) writing to the inspected page'slocalStorageper theDatadogDevtoolswrapper contract; mutations serialized to avoid lost updates.Demo
This is a recording of what the three stacked PRs look like working together.
Screen.Recording.2026-07-24.at.5.14.31.PM.mov
Checklist
useFlagOverrides.spec.ts).