@aurelia/platform
Advanced tools
Comparing version 0.9.0-dev.202101150947 to 0.9.0-dev.202101272007
@@ -29,3 +29,3 @@ "use strict"; | ||
this.flushMacroTask = this.flushMacroTask.bind(this); | ||
this.macroTaskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
this.taskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
} | ||
@@ -59,3 +59,3 @@ static getOrCreate(g, overrides = {}) { | ||
this.macroTaskRequested = false; | ||
this.macroTaskQueue.flush(); | ||
this.taskQueue.flush(); | ||
} | ||
@@ -100,3 +100,6 @@ } | ||
get isEmpty() { | ||
return this.processing.length === 0 && this.pending.length === 0 && this.delayed.length === 0; | ||
return (this.pendingAsyncCount === 0 && | ||
this.processing.length === 0 && | ||
this.pending.length === 0 && | ||
this.delayed.length === 0); | ||
} | ||
@@ -103,0 +106,0 @@ /** |
@@ -26,3 +26,3 @@ const lookup = new Map(); | ||
this.flushMacroTask = this.flushMacroTask.bind(this); | ||
this.macroTaskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
this.taskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
} | ||
@@ -56,3 +56,3 @@ static getOrCreate(g, overrides = {}) { | ||
this.macroTaskRequested = false; | ||
this.macroTaskQueue.flush(); | ||
this.taskQueue.flush(); | ||
} | ||
@@ -96,3 +96,6 @@ } | ||
get isEmpty() { | ||
return this.processing.length === 0 && this.pending.length === 0 && this.delayed.length === 0; | ||
return (this.pendingAsyncCount === 0 && | ||
this.processing.length === 0 && | ||
this.pending.length === 0 && | ||
this.delayed.length === 0); | ||
} | ||
@@ -99,0 +102,0 @@ /** |
@@ -16,3 +16,3 @@ export declare class Platform<TGlobal extends typeof globalThis = typeof globalThis> { | ||
readonly performanceNow: () => number; | ||
readonly macroTaskQueue: TaskQueue; | ||
readonly taskQueue: TaskQueue; | ||
constructor(g: TGlobal, overrides?: Partial<Exclude<Platform, 'globalThis'>>); | ||
@@ -19,0 +19,0 @@ static getOrCreate<TGlobal extends typeof globalThis = typeof globalThis>(g: TGlobal, overrides?: Partial<Exclude<Platform, 'globalThis'>>): Platform<TGlobal>; |
{ | ||
"name": "@aurelia/platform", | ||
"version": "0.9.0-dev.202101150947", | ||
"version": "0.9.0-dev.202101272007", | ||
"main": "dist/cjs/index.js", | ||
@@ -5,0 +5,0 @@ "module": "dist/esm/index.js", |
@@ -38,3 +38,3 @@ const lookup = new Map<object, Platform>(); | ||
public readonly macroTaskQueue: TaskQueue; | ||
public readonly taskQueue: TaskQueue; | ||
@@ -62,3 +62,3 @@ public constructor(g: TGlobal, overrides: Partial<Exclude<Platform, 'globalThis'>> = {}) { | ||
this.flushMacroTask = this.flushMacroTask.bind(this); | ||
this.macroTaskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
this.taskQueue = new TaskQueue(this, this.requestMacroTask.bind(this), this.cancelMacroTask.bind(this)); | ||
} | ||
@@ -100,3 +100,3 @@ | ||
this.macroTaskRequested = false; | ||
this.macroTaskQueue.flush(); | ||
this.taskQueue.flush(); | ||
} | ||
@@ -129,3 +129,8 @@ } | ||
public get isEmpty(): boolean { | ||
return this.processing.length === 0 && this.pending.length === 0 && this.delayed.length === 0; | ||
return ( | ||
this.pendingAsyncCount === 0 && | ||
this.processing.length === 0 && | ||
this.pending.length === 0 && | ||
this.delayed.length === 0 | ||
); | ||
} | ||
@@ -132,0 +137,0 @@ |
Sorry, the diff of this file is not supported yet
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
137598
2211