import { Domain } from "https://deno.land/x/effector@effector-vue%4023.1.0/packages/effector/index.d.ts";
A way to group and process events, stores and effects. Useful for logging and assigning a reset trigger to many effects. Domain is notified via onCreateEvent, onCreateStore, onCreateEffect, onCreateDomain methods when events, stores, effects, or nested domains are created
Properties
compositeName: CompositeName
history: { domains: Set<Domain>; stores: Set<StoreWritable<any>>; effects: Set<Effect<any, any, any>>; events: Set<EventCallable<any>>; }
readonly
kind: kindMethods
createDomain(name?: string): Domain
createEffect<FN extends Function>(handler: FN): EffectByHandler<FN, Error>
createEffect<Params, Done, Fail = Error>(handler: (params: Params) => Done | Promise<Done>): Effect<Params, Done, Fail>
createEffect<FN extends Function, Fail>(handler: FN): EffectByHandler<FN, Fail>
createEffect<FN extends Function>(config: { name?: string; handler: FN; sid?: string; }): EffectByHandler<FN, Error>
createEffect<Params, Done, Fail = Error>(name?: string, config?: { handler?: (params: Params) => Promise<Done> | Done; sid?: string; }): Effect<Params, Done, Fail>
createEffect<Params, Done, Fail = Error>(config: { handler?: (params: Params) => Promise<Done> | Done; sid?: string; name?: string; }): Effect<Params, Done, Fail>
createEvent<Payload = void>(name?: string): EventCallable<Payload>
createEvent<Payload = void>(config: { name?: string; sid?: string; }): EventCallable<Payload>
createStore<State, SerializedState extends Json = Json>(defaultState: State, config?: { name?: string; sid?: string; updateFilter?: (update: State, current: State) => boolean; serialize?: "ignore" | { write: (state: State) => SerializedState; read: (json: SerializedState) => State; }; }): StoreWritable<State>
effect<FN extends Function>(handler: FN): EffectByHandler<FN, Error>
effect<FN extends Function, Fail>(handler: FN): EffectByHandler<FN, Fail>
event<Payload = void>(name?: string): EventCallable<Payload>
event<Payload = void>(config: { name?: string; sid?: string; }): EventCallable<Payload>
getType(): string
onCreateDomain(hook: (newDomain: Domain) => any): Subscription
onCreateEffect(hook: (newEffect: Effect<unknown, unknown, unknown>) => any): Subscription
onCreateEvent(hook: (newEvent: EventCallable<unknown>) => any): Subscription
onCreateStore(hook: (newStore: InternalStore<unknown>) => any): Subscription
store<State, SerializedState extends Json = Json>(defaultState: State, config?: { name?: string; sid?: string; updateFilter?: (update: State, current: State) => boolean; serialize?: "ignore" | { write: (state: State) => SerializedState; read: (json: SerializedState) => State; }; }): StoreWritable<State>