Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove bluebird from dependencies #5

Closed
ruiaraujo opened this issue May 10, 2016 · 7 comments
Closed

Remove bluebird from dependencies #5

ruiaraujo opened this issue May 10, 2016 · 7 comments

Comments

@ruiaraujo
Copy link
Contributor

ES6 includes a Promise implementation and even though bluebird one is nice, this library doesn't really need it at all.

@AVVS
Copy link
Member

AVVS commented May 10, 2016

ES6 promises suck. And even though this is highly subjective, it's used in both dependencies of this project, as well this project for iterating over promises.

On a more serious note - they are slower and have no utilities what so ever. Because I'm biased, bluebird implementation is way better and it is also used in every other project that depends on this - it's used here.

On 10 May 2016, at 09:37, Rui Araújo notifications@github.com wrote:

ES6 includes a Promise implementation and even though bluebird one is nice, this library doesn't really need it at all.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub

@ruiaraujo
Copy link
Contributor Author

ruiaraujo commented May 10, 2016

My suggestion was to make the library consumer provide the Promise polyfill of their liking. Bluebird is giant compared to other polyfills, 18x bigger (170kb vs 9kb before minification) than the one I currently use.
But since it is your project, I will just fork it and remove it myself. ;)

@AVVS
Copy link
Member

AVVS commented May 10, 2016

Gzip helps with the size + prod build is even smaller. I suggest creating 2 bundles - vendor and app code. Then vendor is loaded and cached once for a year and you dont have to sacrifice functionality for a little smaller bundle. Also cdn can serve it all.

As for polyfilling it - I havent found a good solution to overload base babel promise polyfill. Maybe you can help me here? It has to work on both server side and client side, do not export default babel polyfill (should be library of choice). If you can help with that - then I will add it to readme and remove bluebird as there would be a working solution for bundling it in another way

On 10 May 2016, at 10:06, Rui Araújo notifications@github.com wrote:

My suggestion was to make the library consumer provide the Promise polyfill of their liking. Bluebird is giant compared to other polyfills, 20x bigger (190kb vs 9kb) than the one I currently use.
But since it is your project, I will just fork it and remove it myself. ;)


You are receiving this because you commented.
Reply to this email directly or view it on GitHub

@ruiaraujo
Copy link
Contributor Author

About polyfilling check the end of this page https://github.com/babel/babel-loader

@fabiozaffani
Copy link

I'm also interested in this, i notice the final size increased a lot due to bluebird being included as an dependency.

@AVVS
Copy link
Member

AVVS commented May 12, 2016

Please take a look at #10

@AVVS
Copy link
Member

AVVS commented May 12, 2016

closed via 2bc1c45

@AVVS AVVS closed this as completed May 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants