Optional
destroyer: (() => void)Private
Optional
Readonly
_destroyerProtected
_listenersPrivate
_valueSet the value, and dispatch to all listeners.
Add a listener for when this Observable changes.
Creates a new Observable whose value is derived from another Observable. The new Observable automatically updates and notifies listeners whenever the source Observable changes.
const value = createObservable(2);
const isGreater = value.computed((value) => value > 5);
// > isGreater == false;
value.dispatch(6);
// > isGreater == true;
Set's the new value, and calls all the listeners. You can additionaly set the value directly.
Remove a listener for when this Observable changes.
Generated using TypeDoc
A class that holds a value and notifies whenever the value changes.
See
https://github.com/nombrekeff/cardboard-js/wiki/Observers