A Riduce-standard action, produced by Riduce's actions and create API.
It builds off Flux-Standard Actions, but adds a leaf property, which is used by Riduce's reducer to identify which state to update and how.
interface Action<PayloadT = unknown> {
type: string;
leaf: LeafData;
payload?: PayloadT;
}
The presence of the leaf property has two handy properties:
type exclusively for debugging: since leaf contains the data needed for Riduce's reducer to update state, the type property can be used exclusively for debugging and readability - see Control action typesleaf is guaranteed to be present on all Riduce actions, it can be used to help gradually migrate from legacy reducers - see Migrating from legacy reducersRelated types: