StatefulEvt<T>
.state
.stateimport { Evt } from "evt";
const evtCount = Evt.create(0); // Equivalent wit new StatefulEvt<number>(0)
evtCount.attach(console.log);
console.log(evtCount.state); //Pints "state: 0"
evtIsConnected.post(1); //Pints "1"
console.log(evtCount.state); //Prints "1";
evtCount.state++; //Prints "2"
console.log(evtCount.state); //Pints "2";.evtChange
.evtChange.evtDiff
.evtDiff.evtChangeDiff
.evtChangeDiff.pipe(...)
.pipe(...)Converting an Evt into a StatefulEvt
Evt into a StatefulEvtMerging multiple StatefulEvts
StatefulEvtsMake a StatefulEvt readonly
StatefulEvt readonly.postFoceChange()
.postFoceChange().toStateless([ctx])
.toStateless([ctx])Last updated