Home Manual Reference Source Repository

Typedef

Static Public Summary
public

Creates an object consumable by Redux

public

A function that defines a namespace for creating slices

public

An object containing base type, subtypes, and a payload creator

Static Public

public ActionCreator: function source

Creates an object consumable by Redux

public ActionFactory: ActionFactory: function source

A function that defines a namespace for creating slices

Return:

ActionFactory

ActionSlice creator

public ActionSlice: object source

An object containing base type, subtypes, and a payload creator

Properties:

NameTypeAttributeDescription
BASE_TYPE String

Action base type with factory and slice name

...actionTypes ...Object

Type names for each actionType given

requestPayloadCreator Function

For creating payloads of REQUEST actions*

Example:

{
 BASE_TYPE: "TODO/ADD",
 REQUEST: "TODO/ADD/REQUEST",
 SUCCESS: "TODO/ADD/SUCCESS",
 FAILURE: "TODO/ADD/FAILURE"
 requestPayloadCreator: ({ text, title, listId: list_id }) => ({ text, title, list_id})
}