Skip to content

useUpdateConfigReducer

useUpdateConfigReducer<TConfig, TPayload>(reducer): UseUpdateConfigReducerResult<TConfig, TPayload>

Defined in: packages/react/src/hooks.ts:147

Hook to update the configuration using a Reducer pattern. Best for complex logic or reusable actions.

TConfig

The type of the configuration.

TPayload

The type of the action payload accepted by the reducer.

ConfigReducer<TConfig, TPayload>

A function that takes current config and a payload, returning the new config.

UseUpdateConfigReducerResult<TConfig, TPayload>

An object containing the update(payload) function and status flags.