class ReactiveEffect

Properties

active

Signature
active: boolean;

allowRecurse

Signature
allowRecurse?: boolean;

computed

Signature
computed?: boolean;

deps

Signature
deps: Dep[];

fn

Signature
fn: () => T;

onStop

Signature
onStop?: () => void;

onTrack

Signature
onTrack?: (event: DebuggerEvent) => void;

onTrigger

Signature
onTrigger?: (event: DebuggerEvent) => void;

scheduler

Signature
scheduler: EffectScheduler | null;

Constructors

(constructor)(fn, scheduler, scope)

Constructs a new instance of the ReactiveEffect class

Parameters
Name Type Description

fn

() => T

scheduler

EffectScheduler | null

scope

EffectScope | null

Signature
constructor(fn: () => T, scheduler?: EffectScheduler | null, scope?: EffectScope | null);

Methods

run()

Signature
run(): T | undefined;

stop()

Signature
stop(): void;