proxy-state-tree
Advanced tools
Comparing version 1.0.0-1535141908317 to 1.0.0-1535290136520
@@ -1,2 +0,2 @@ | ||
import { IS_PROXY, STATUS } from './proxify'; | ||
import { IS_PROXY } from './proxify'; | ||
export declare type Options = { | ||
@@ -12,13 +12,13 @@ devmode?: boolean; | ||
declare class ProxyStateTree { | ||
state: object; | ||
options: Options; | ||
private state; | ||
private options; | ||
pathDependencies: object; | ||
globalDependencies: Set<Function>; | ||
objectChanges: Set<string>; | ||
mutations: Mutation[]; | ||
currentMutations: Mutation[]; | ||
paths: Set<string>[]; | ||
status: STATUS; | ||
proxy: any; | ||
currentFlushId: number; | ||
private globalDependencies; | ||
private objectChanges; | ||
private mutations; | ||
private currentMutations; | ||
private paths; | ||
private status; | ||
private currentFlushId; | ||
private proxy; | ||
constructor(state: object, options?: Options); | ||
@@ -25,0 +25,0 @@ get(): any; |
@@ -5,8 +5,2 @@ import proxify, { IS_PROXY, STATUS } from './proxify'; | ||
constructor(state, options = {}) { | ||
if (!isPlainObject(state)) { | ||
throw new Error('You did not pass a plain object as state to Proxy State Tree'); | ||
} | ||
if (typeof options.devmode === 'undefined') { | ||
options.devmode = true; | ||
} | ||
this.state = state; | ||
@@ -16,9 +10,15 @@ this.options = options; | ||
this.globalDependencies = new Set(); | ||
this.objectChanges = new Set(); | ||
this.mutations = []; | ||
this.currentMutations = []; | ||
this.paths = []; | ||
this.objectChanges = new Set(); | ||
this.status = STATUS.IDLE; | ||
this.currentFlushId = 0; | ||
if (!isPlainObject(state)) { | ||
throw new Error('You did not pass a plain object as state to Proxy State Tree'); | ||
} | ||
if (typeof options.devmode === 'undefined') { | ||
options.devmode = true; | ||
} | ||
this.proxy = proxify(this, state); | ||
this.currentFlushId = 0; | ||
} | ||
@@ -25,0 +25,0 @@ get() { |
@@ -1,2 +0,2 @@ | ||
import { IS_PROXY, STATUS } from './proxify'; | ||
import { IS_PROXY } from './proxify'; | ||
export declare type Options = { | ||
@@ -12,13 +12,13 @@ devmode?: boolean; | ||
declare class ProxyStateTree { | ||
state: object; | ||
options: Options; | ||
private state; | ||
private options; | ||
pathDependencies: object; | ||
globalDependencies: Set<Function>; | ||
objectChanges: Set<string>; | ||
mutations: Mutation[]; | ||
currentMutations: Mutation[]; | ||
paths: Set<string>[]; | ||
status: STATUS; | ||
proxy: any; | ||
currentFlushId: number; | ||
private globalDependencies; | ||
private objectChanges; | ||
private mutations; | ||
private currentMutations; | ||
private paths; | ||
private status; | ||
private currentFlushId; | ||
private proxy; | ||
constructor(state: object, options?: Options); | ||
@@ -25,0 +25,0 @@ get(): any; |
@@ -8,8 +8,2 @@ "use strict"; | ||
constructor(state, options = {}) { | ||
if (!isPlainObject(state)) { | ||
throw new Error('You did not pass a plain object as state to Proxy State Tree'); | ||
} | ||
if (typeof options.devmode === 'undefined') { | ||
options.devmode = true; | ||
} | ||
this.state = state; | ||
@@ -19,9 +13,15 @@ this.options = options; | ||
this.globalDependencies = new Set(); | ||
this.objectChanges = new Set(); | ||
this.mutations = []; | ||
this.currentMutations = []; | ||
this.paths = []; | ||
this.objectChanges = new Set(); | ||
this.status = proxify_1.STATUS.IDLE; | ||
this.currentFlushId = 0; | ||
if (!isPlainObject(state)) { | ||
throw new Error('You did not pass a plain object as state to Proxy State Tree'); | ||
} | ||
if (typeof options.devmode === 'undefined') { | ||
options.devmode = true; | ||
} | ||
this.proxy = proxify_1.default(this, state); | ||
this.currentFlushId = 0; | ||
} | ||
@@ -28,0 +28,0 @@ get() { |
{ | ||
"name": "proxy-state-tree", | ||
"version": "1.0.0-1535141908317", | ||
"version": "1.0.0-1535290136520", | ||
"description": "An implementation of the Mobx/Vue state tracking approach, for library authors", | ||
@@ -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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
212735