FluidAsyncStateUpdateFunction Interface

Packages > @fluidframework/react > FluidAsyncStateUpdateFunction

Definition for an async state update function used in reducers

Signature:

export interface FluidAsyncStateUpdateFunction<SV extends IViewState, SF extends IFluidState, C extends IFluidDataProps> 

Properties

List of properties of this interface
Property Type Description
asyncFunction (oldState?: ICombinedState, ...args: any) => Promise<IStateUpdateResult> The function defined here will take the combined state and update either the Fluid state, the view state, or both in an async manner. The new combined state and any new Fluid object handles to load in will be returned by the function when it finishes.

Events

asyncFunction

The function defined here will take the combined state and update either the Fluid state, the view state, or both in an async manner. The new combined state and any new Fluid object handles to load in will be returned by the function when it finishes.

Signature:

asyncFunction: (oldState?: ICombinedState<SV, SF, C>, ...args: any) => Promise<IStateUpdateResult<SV, SF, C>>;