import type { ActionPattern } from 'redux-saga/effects'; import type { DefaultFn } from '../../../types'; declare type Unit = { pattern: ActionPattern; task: DefaultFn; }; /** * The flow is simple: * - wait for a trigger (handles take(unit.pattern) effect) * - execute task (handles call(unit.task, result)) * - and repeat the same steps for next unit * * const UnitShape = { * pattern: {String|Array|Function} - pattern for the take effect * task: Function - receives result of the above take effect as first argument * } */ export declare function simpleCircuit(units?: Unit[]): Generator; /** * First unit is executed, * then all the units from index 1, to last index - 2, * if during exucution of those intermediate units * is triggered pattern of last unit, the intermediate units are cancelled * and task of the last unit is executed. */ export declare function deepCircuit(units?: Unit[]): Generator; export {};