RecentQueriesActions
RecentQueriesActions
This is for:
DeveloperThe commerce recent queries action creators.
See Dispatch Actions.
Loader Function
loadRecentQueriesActions
Loads the recent queries reducer and returns available commerce recent queries actions.
Parameters
-
engine:
CommerceEngine
The headless commerce engine.
Returns RecentQueriesActionCreators
: The commerce recent queries action creators.
RecentQueriesActionCreators
clearRecentQueries
Clears the recent queries list.
Returns PayloadAction
: A dispatchable action.
registerRecentQueries
Initializes the recent queries state.
Parameters
-
payload:
RegisterRecentQueriesCreatorPayload
The action creator payload.
Returns PayloadAction<RegisterRecentQueriesCreatorPayload>
: A dispatchable action.
Related Types
RegisterRecentQueriesCreatorPayload
Properties
-
maxLength:
number
The maximum number of queries to retain in the list.
-
queries:
string[]
The recent queries made by the user prior to instantiating the controller.