(script: string)
| 79 | } |
| 80 | |
| 81 | enqueue(script: string) { |
| 82 | if (this._cleanedUp) return |
| 83 | this._queue.push(script) |
| 84 | // If barrier is lifted, schedule injection (if not already scheduled) |
| 85 | if (this._scriptBarrierLifted && !this._pendingMicrotask) { |
| 86 | this._pendingMicrotask = true |
| 87 | queueMicrotask(() => { |
| 88 | this._pendingMicrotask = false |
| 89 | this.injectBufferedScripts() |
| 90 | }) |
| 91 | } |
| 92 | } |
| 93 | |
| 94 | liftBarrier() { |
| 95 | if (this._scriptBarrierLifted || this._cleanedUp) return |