A polyfill library covering ECMAScript features through current standards plus selected web-platform APIs, with modular imports.
Overview
core-js supplies JavaScript polyfills and shims so applications can rely on language and platform APIs that older or incomplete runtimes lack. Coverage spans promises, collections, iterators, typed arrays, symbols, and many staged ECMAScript proposals, along with selected WHATWG and W3C pieces such as URL handling.
You can import the full standard set, pull only specific modules to keep bundles smaller, or use a pure build that avoids mutating global prototypes. Feature detection decides when a native implementation is already sufficient, and aggressiveness can be tuned for stricter environments.
The project integrates with Babel, SWC, and related tooling so bundlers inject only the polyfills a target browser needs. A companion compatibility dataset helps tools map language features to required modules. Custom builds can exclude features or target particular engines.
Documentation and examples show both global and ponyfill-style usage patterns for modern syntax such as iterators and structured cloning.
Key features
- Granular polyfill modules
- ECMAScript proposal coverage
- Pure non-global mode
- Babel and SWC integration
- Compatibility metadata package
- Custom build tooling
- Web platform shims
- Configurable polyfill aggressiveness
Use cases
- Supporting legacy browsers
- Enabling new syntax via transpilers
- Filling partial JavaScript runtimes