A lightweight polyfill for ES6 Promises, extracted from rsvp.js, to provide native Promise support in older environments.
ES6-Promise is a polyfill that implements the ES6 Promise specification, allowing developers to use modern asynchronous JavaScript patterns in environments that do not natively support Promises. It solves the problem of inconsistent or missing Promise implementations in older browsers and Node.js versions, ensuring reliable async operations. The library is a lightweight subset extracted from rsvp.js, focusing on core functionality without extra features.
JavaScript developers working on projects that need to support legacy browsers (like IE<9) or older Node.js environments, and those who require a minimal, standards-compliant promise polyfill.
Developers choose ES6-Promise for its strict adherence to the ES6 standard, small size, and automatic polyfilling capability, which simplifies integration and ensures compatibility without the overhead of larger promise libraries.
A polyfill for ES6-style Promises
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Implements the complete ES6 Promise API, ensuring interoperability with native promises and strict adherence to the specification, as highlighted in the project's description.
Extracted from rsvp.js as a subset, it has a small footprint with minified versions around 2.4 KB gzipped, focusing on core functionality without bloat.
The auto version patches the global Promise object if missing or broken, simplifying integration in legacy environments without manual checks, as shown in the CDN and usage examples.
Works across legacy browsers like IE<9 and older Node.js versions, making it essential for maintaining compatibility in mixed or outdated projects.
Available via CDN for quick inclusion and through npm/yarn for build integration, offering flexible methods to add promise support, as detailed in the downloads and installation sections.
As a subset of rsvp.js, it lacks features like promise cancellation, progress events, and enhanced debugging options available in fuller libraries, limiting its utility for complex async patterns.
In IE<9, methods such as 'catch' and 'finally' are reserved keywords, requiring awkward syntax workarounds or reliance on minifiers, adding complexity for legacy support.
Only polyfills Promises; async/await syntax still requires additional transpilation (e.g., Babel) in environments without native support, which isn't addressed by this library.
In projects targeting only modern browsers with native Promise support, including this polyfill introduces unnecessary code bloat and potential performance overhead.