API reference › @evolu/common › Polyfills › installPolyfills
function installPolyfills(): void;
Defined in: packages/common/src/Polyfills.ts:35
Installs polyfills required by @evolu/common.
Installs:
- Resource-management polyfills (
Symbol.dispose,Symbol.asyncDispose,DisposableStack,AsyncDisposableStack, andSuppressedError) for Safari and React Native MapandWeakMapupsert polyfills (Map.prototype.getOrInsert,Map.prototype.getOrInsertComputed,WeakMap.prototype.getOrInsert, andWeakMap.prototype.getOrInsertComputed) for Node 24 and React Native
The polyfills are implemented directly in the Evolu Library instead of being third-party runtime dependencies. We audit their behavior against specifications, conformance tests, and native implementations, and fix issues when necessary. This lets Evolu understand and control every line of this runtime code.
@evolu/react-native has its own Polyfills module and its
installPolyfills calls this function first, then installs React Native
specific polyfills.
Call this explicitly from the app entry point.