type FlowStateWith<S, K, V> = string extends K ? S : { [P in keyof S | K]: P extends K ? V : P extends keyof S ? S[P] : never };
Defined in: flows/FlowBuilder.ts:54S with key K set to V (replacing any previous type of K). A non-literal key
(K = string) cannot be tracked, so S is returned unchanged — the value stays reachable
as unknown through the open index signature of FlowControls.