@qiwi/cyclone
Version:
"State machine" for basic purposes
15 lines (14 loc) • 615 B
TypeScript
import { IMachine, IMachineOpts } from './machine';
import { Registry } from './registry';
export declare const DEFAULT_TEMPLATE: {};
export declare const DEFAULT_TEMPLATE_REGISTRY: Registry;
export declare const DEFAULT_MACHINE_REGISTRY: Registry;
declare type IFactoryOpts = {
machine?: IMachineOpts;
template?: string | Object;
templateRegistry?: Registry;
machineRegistry?: Registry;
};
export declare const factory: (opts: IFactoryOpts) => IMachine;
export declare const getTemplate: (template: string | Object | void, templateRegistry: Registry) => any;
export { IFactoryOpts };