Comments (7)
The reason why es-shims/Promise.allSettled
has such a huge bundle size is that they're bundling a lot of dependencies.
Here is a polyfill in 218 bytes.
Would love to see this in es6-promise, which is my favorite promise polyfill ❤️
from es6-promise.
As a long-time user of this package, it never occured to me that it its features could be scoped to ES2015. I guess it's because we've been using "ES6" as an inaccurate alias for "the time when we got new JavaScript features" for so long.
In any case, other packages I use have started to use allSettled
, and they rarely make the destinction between ES levels. They just assume window.Promise
is supported with the current promise features. If this package would remain scoped to ES2015, I could no longer use it as an effective IE11 polyfill.
from es6-promise.
I just checked the bundle size for es-shims/Promise.allSettled
and it's 31.5 kB (es6-promise
is 6.2 kB). I'm not sure if it will weight less if reimplemented here, but the bundle size of es-shims/Promise.allSettled
was definitely the reason I didn't use it in my project
from es6-promise.
Wow thats pretty large.
from es6-promise.
This project is named es6-promise, and es6 doesn't have all-settled, or other new features.
If there is enough demand, we can create a different polyfil. But it is unclear if adding it here, given the name, makes sense.
Thoughts?
from es6-promise.
I don't think much people rely on the fact that ES2015 doesn't contain allSettled
. I personally expect from a polyfill a "full support" (whatever this could mean). But overall can't judge if the name is a deciding factor in this situation. A different polyfill definitely wouldn't hurt, but it could be a split effort for almost same thing.
I guess changing this project name isn't an option?
from es6-promise.
I implemented this method https://github.com/WormGirl/core-promise
from es6-promise.
Related Issues (20)
- Intercepting `Promise.resolve` fails in `enumerator.js#L82`
- ES6Promise.Promise.prototype.finally does not behave according to spec HOT 3
- Library outdated on cdnjs
- Consider enabling the daily build in TravisCI
- The automatic polyfill fails when both 'window' and 'global' exist.
- Add `unpkg` and `jsdelivr` properties to package.json which point at dist version HOT 1
- Accessing `then` on a `function` or `object` throws within the `getThen` helper HOT 6
- Inconsistent type on `Thenable.then` overload? HOT 1
- Promise.prototype.catch IE8 Expected identifier error HOT 1
- Why are you using setTimeout(1) instead of setTimeout(0)? HOT 4
- .d.ts incompatible with TypeScript lib definitions
- ie9 catch error HOT 2
- Error: 'Promise' is not exported HOT 1
- Is it required to include both scripts in html page? HOT 2
- Update CHANGELOG with 4.2.6, 4.2.7, 4.2.8?
- Switch build to Babel 7? HOT 1
- The output sequence is not consistent with native performance HOT 1
- incompatible with ie11 + babel + webpack
- Mau claim produk yang telah saya gunakan untuk konfirmasi hasil yang maksimal di perangkat Android yang telah saya mainkan verryhadisaputra
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from es6-promise.