mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-12-22 12:41:41 +03:00
parent
9f3dceb220
commit
055fa0a8b4
@ -1,4 +1,5 @@
|
||||
import { polyfillDispose } from './dispose';
|
||||
import { polyfillIteratorHelpers } from './iterator-helpers';
|
||||
import { polyfillPromise } from './promise-with-resolvers';
|
||||
import { polyfillEventLoop } from './request-idle-callback';
|
||||
import { polyfillResizeObserver } from './resize-observer';
|
||||
@ -7,3 +8,4 @@ polyfillResizeObserver();
|
||||
polyfillEventLoop();
|
||||
await polyfillPromise();
|
||||
await polyfillDispose();
|
||||
await polyfillIteratorHelpers();
|
||||
|
@ -0,0 +1,7 @@
|
||||
export async function polyfillIteratorHelpers() {
|
||||
if (typeof globalThis['Iterator'] !== 'function') {
|
||||
// @ts-expect-error ignore
|
||||
// https://github.com/zloirock/core-js/blob/master/packages/core-js/proposals/iterator-helpers-stage-3.js
|
||||
await import('core-js/proposals/iterator-helpers-stage-3');
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user