Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const update = (newState: StateObject, stop: () => void) => {
if (this.opts && this.opts.includeUnresolved || newState.resolved) {
if (skipFirst) {
skipFirst = false;
} else {
once && stop();
const oldState = this._currentState;
this._currentState = fromStateObject(newState);
_internal.processChangedAtom(this, oldState, this.version++);
}
}
};
const cleanup = () => {