1.0.0 • Published 3 years ago
@issimo/deep-state v1.0.0
A simple state store. Performs a deep comparison before calling the callbacks.
const state = State();
const cleanup = state.subscribe((prev, next) => {
// stuff
});
state.value = { foo: "bar" }; // trigger callback
state.value = { foo: "bar" }; // nothing
1.0.0
3 years ago