import { attach } from "https://dotland.deno.dev/x/effector@effector-vue%4023.1.0/packages/effector/index.d.ts";
Method for creating state-dependent effect and transforming effect payloads
Method for transforming effect payloads
Type Parameters
FX extends Effect<any, any, any>
Parameters
config: { effect: FX; mapParams: FN extends (...args: any[]) => NoInfer<EffectParams<FX>> ? FN : never; name?: string; }
Returns
FN extends (...args: infer Args) => NoInfer<EffectParams<FX>> ? Effect<Args["length"] extends 0 ? void : 0 | 1 extends Args["length"] ? Args[0] | void : Args[0], EffectResult<FX>, EffectError<FX>> : never
new effect
Method for transforming effect payloads
Type Parameters
FX extends Effect<any, any, any>
Parameters
config: { effect: FX; mapParams: (params: Params) => NoInfer<EffectParams<FX>>; name?: string; }
Creates state-dependent effect with provided function handler. Allows the one to omit intermediate effects and declare effect handler right next to data source
Type Parameters
FX extends (state: GetShapeValue<States>, params: any) => any
Creates independent instance of given effect. Used to add subscribers to effect call in a particular business case
Type Parameters
FX extends Effect<any, any, any>
Parameters
config: { effect: FX; name?: string; }
Method for creating state-dependent effect and transforming effect payload
Type Parameters
FX extends Effect<any, any, any>
FN extends ((params: any, source: GetShapeValue<States>) => NoInfer<EffectParams<FX>>)