Actions
Share your State Changes with Actions.
You can create Action's for State changes in the ngrx-lite/component-store or State changes in the loadingEffect
in the ngrx-lite/loading-store
getCustomAction
warning
This Methode not support the lazy Functional ngrx-lite/component-store.
To support lazy Functional Stores please use getCustomActionWithDynamicStore
Get an Action for the ngrx-lite/component-store or ngrx-lite/loading-store
effect.action.ts
const myEffectAction = getCustomAction({
storeName: 'storeName',
actionName: 'myAction',
});
getCustomActionWithDynamicStore
Get an Action for the lazy Functional ngrx-lite/component-store
effect.action.ts
const myEffectAction = getCustomActionWithDynamicStore<'StoreA'>({
storeName: 'storeName',
dynamicStoreName: 'StoreA',
actionName: 'myAction',
});
getEffectAction
Get an Action for the loadingEffect
(Load,Success or Error) in the ngrx-lite/loading-store
effect.action.ts
const myEffectAction = getEffectAction({
storeName: 'storeName',
effectName: 'incrementEffectName',
dynamicStoreName: 'StoreA',
type: EffectStates.SUCCESS,
});