@zedux/core
Version:
A high-level, declarative, composable form of Redux
19 lines (18 loc) • 762 B
TypeScript
import { Action, ActionChain } from '../types';
/**
* Returns the value of the metaData field of the first ActionMeta object in the
* chain with the given metaType.
*/
export declare const getMetaData: (action: ActionChain, metaType: string) => any;
/**
* Strips all ActionMeta nodes off an ActionChain and returns the wrapped Action
*/
export declare const removeAllMeta: (action: ActionChain) => Action<any, string, any>;
/**
* Removes the first found meta node with the given metaType in the given action
* chain.
*
* The metaType does not have to exist in the action chain (though this'll be
* pretty inefficient and wasteful if it doesn't).
*/
export declare const removeMeta: (action: ActionChain, metaType: string) => ActionChain<any, string>;