UseUpdateConfigReducerResult
Defined in: packages/react/src/types.ts:116
Return value of the useUpdateConfigReducer hook.
Contains the dispatched update function and the current status of the save operation.
Type Parameters
Section titled “Type Parameters”TConfig
Section titled “TConfig”TConfig
TPayload
Section titled “TPayload”TPayload
Properties
Section titled “Properties”error:
unknown
Defined in: packages/react/src/types.ts:136
The error object if the save operation failed.
isError
Section titled “isError”isError:
boolean
Defined in: packages/react/src/types.ts:132
True if save status is ‘error’.
isInitial
Section titled “isInitial”isInitial:
boolean
Defined in: packages/react/src/types.ts:126
True if save status is ‘initial’.
isPending
Section titled “isPending”isPending:
boolean
Defined in: packages/react/src/types.ts:128
True if save status is ‘pending’.
isSuccess
Section titled “isSuccess”isSuccess:
boolean
Defined in: packages/react/src/types.ts:130
True if save status is ‘success’.
status
Section titled “status”status:
ManagerStatus
Defined in: packages/react/src/types.ts:134
The specific status of the save operation.
Methods
Section titled “Methods”update()
Section titled “update()”update(
payload):Promise<TConfig>
Defined in: packages/react/src/types.ts:123
Updates the config by dispatching a payload to the defined reducer.
Parameters
Section titled “Parameters”payload
Section titled “payload”TPayload
The value passed into the update function that the reducer must apply to the config
Returns
Section titled “Returns”Promise<TConfig>
The entire modified config