Socket
Socket
Sign inDemoInstall

mobservable

Package Overview
Dependencies
0
Maintainers
1
Versions
79
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.0 to 1.2.1

4

CHANGELOG.md

@@ -0,1 +1,5 @@

# 1.2.1
* Computed value now yields consistent results when being inspected while in transaction
# 1.2.0

@@ -2,0 +6,0 @@

export declare function checkIfStateIsBeingModifiedDuringView(context: IContextInfoStruct): void;
export declare function transaction<T>(action: () => T, thisArg?: any): T;
export declare function runAfterTransaction(action: () => void): void;
export declare function isInTransaction(): boolean;
export declare function untracked<T>(action: () => T): T;

@@ -5,0 +6,0 @@ export declare enum NodeState {

@@ -49,2 +49,6 @@ /**

exports.runAfterTransaction = runAfterTransaction;
function isInTransaction() {
return inTransaction > 0;
}
exports.isInTransaction = isInTransaction;
function untracked(action) {

@@ -51,0 +55,0 @@ try {

@@ -33,2 +33,5 @@ /**

throw new Error("[mobservable.view '" + this.context.name + "'] Cycle detected");
if (this.state === dnode_1.NodeState.STALE && dnode_1.isInTransaction()) {
return this.func.call(this.scope);
}
if (this.isSleeping) {

@@ -35,0 +38,0 @@ if (dnode_1.isComputingView()) {

2

package.json
{
"name": "mobservable",
"version": "1.2.0",
"version": "1.2.1",
"description": "Observable data. Reactive functions. Simple code.",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc