petkaantonov/bluebird
View on GitHub ↗ ★ 20,467 JavaScript
:bird: :zap: Bluebird is a full featured promise library with unmatched performance.
87 mentions on Hacker News by 66 people: 13 stories, 74 comments · first 2013-10-04 · latest 2022-08-24
20082026
-
…callback hell and having to perform error handling in multiple places. A good Promise library (like https://github.com/petkaantonov/bluebird ) even provides mechanisms for writing functions that both return Promises as well as accept…
comment by hiddentao · 2014-07-20 · in JavaScript (and Node) Best Practices -
His "optimization killers" article is also really insightful: https://github.com/petkaantonov/bluebird/wiki/Optimization-k...
comment by sheetjs · 2014-06-24 · in Show HN: Fast.js – faster reimplementations of native JavaScript functions -
…are some cases where you must use inline for loops (such as when slicing arguments objects, see https://github.com/petkaantonov/bluebird/wiki/Optimization-k... ) and a function call is not possible. These can also be addressed with…
comment by phpnode · 2014-06-24 · in Show HN: Fast.js – faster reimplementations of native JavaScript functions -
…https://github.com/kriskowal/q#long-stack-traces [3] https://github.com/btford/zone.js/#zonefork [4] https://github.com/petkaantonov/bluebird
comment by munro · 2014-05-29 · in Zones – Robust error handling and flow control for Node.js -
…I recall hearing that variables mixed with literals in a switch could trip up the optimizer. [1] https://github.com/petkaantonov/bluebird/wiki/Optimization-k...
comment by XaspR8d · 2014-05-14 · in Emulating a BBC Microcomputer in Javascript -
Petka Antonov (the author) wrote this: https://github.com/petkaantonov/bluebird/wiki/Optimization-k... Other than that, I think he also said similar rules of C++ and Java optimization apply (avoid allocations a.k.a. creations of new…
comment by spion · 2014-04-30 · in JavaScript Promises in Wicked Detail -
…a github issue? (or is mongoose doing something so crazy that it cannot be helped at all? :P) [1] https://github.com/petkaantonov/bluebird/commit/70f90c33dd94...
comment by esailija · 2014-04-26 · in Better JavaScript Promises -
…3 simultaneous async requests, it's super easy with promises. Here's an example using bluebird ( https://github.com/petkaantonov/bluebird ): Promise.all([async1, async2, async3]).then(function(results) { console.log('async1:', results[0]);…
comment by jclem · 2014-04-25 · in Better JavaScript Promises -
As long as the library follows the "function (err, data)" convention: https://github.com/petkaantonov/bluebird/blob/master/API.md#...
comment by unspecified · 2014-04-18 · in Write Better JavaScript with Promises -
ok... then can you explain what's happening here: https://github.com/petkaantonov/bluebird/blob/master/js/brow... Where the line checks for `window.Promise`
comment by lightblade · 2014-02-18 · in How I want to write Node: Stream all the things -
- Why BlueBird? What's wrong with Q? - Isn't data a scope down? - https://github.com/petkaantonov/bluebird/blob/master/API.md is API based, not task based. async is API based too, but the API has names like 'waterfall' and 'parallel'. I…
comment by nailer · 2014-02-14 · in How I want to write Node: Stream all the things -
…Promise.spawn(function* () { var data = yield fs.readFileAsync(somefile); }); Documentation: https://github.com/petkaantonov/bluebird/blob/master/API.md My favorite example is doing a diff using an async diff service which provides a…
comment by spion · 2014-02-14 · in How I want to write Node: Stream all the things -
Bluebird is the best promises library: https://github.com/petkaantonov/bluebird
comment by jonny_eh · 2014-02-14 · in How I want to write Node: Stream all the things -
I would not say this[1] is a minimal difference :P [1]: https://github.com/petkaantonov/bluebird/blob/master/benchma...
comment by esailija · 2014-02-05 · in Managing Node.js Callback Hell with Promises, Generators and Other Approaches -
…promise articles/tutorials reference Q as the preferred promise library, rather than bluebird - https://github.com/petkaantonov/bluebird Bluebird is not only so fast that it's almost on par with callbacks[1], but also innovates on the…
comment by tgriesser · 2014-02-04 · in Managing Node.js Callback Hell with Promises, Generators and Other Approaches -
…CSS) but these don't dictate how you structure your code so there's still room for conflict. [1] https://github.com/petkaantonov/bluebird/blob/master/API.md#...
comment by grayrest · 2014-02-03 · in Grunt and RequireJS are out, it's all about Gulp and Browserify -
…PromiseThatMissesThePointOfPromises { ... Please point out anything I am misunderstanding. [1] https://github.com/petkaantonov/bluebird/issues/51 [2] https://github.com/petkaantonov/bluebird/issues/51#issuecomm...
comment by eldude · 2014-01-08 · in Why I am switching to promises -
…even if that weren't the case, it would be a simple matter to write a more specific wrapper. [1]: https://github.com/petkaantonov/bluebird/issues/51#issuecomm...
comment by spion · 2014-01-08 · in Why I am switching to promises -
…and Q seems to be shockingly slow compared to the dozen or so other promise libraries out there. 1. https://github.com/petkaantonov/bluebird 2. http://spion.github.io/posts/why-i-am-switching-to-promises....
comment by JoshGlazebrook · 2013-12-17 · in JavaScript Promises: There and back again -
Here you go! https://github.com/petkaantonov/bluebird/issues/5
comment by antihero · 2013-10-05 · in Bluebird – A full-featured, fast promises library for JavaScript -
Hmm. Can you post your code and description of the problem as an issue? https://github.com/petkaantonov/bluebird/issues
comment by esailija · 2013-10-04 · in Bluebird – A full-featured, fast promises library for JavaScript -
…of the async event chain 3. I will skip this, because, uhh... 4. You didn't look hard enough. https://github.com/petkaantonov/bluebird/tree/master/src 5. Yes, promises are confusing. I'm going to write a straight-forward introduction (that…
comment by spion · 2013-10-04 · in Bluebird – A full-featured, fast promises library for JavaScript -
…figure out a way to do it). Bluebird looks promising, but IE<9 isn't supported at the moment ( https://github.com/petkaantonov/bluebird/issues/3 ). Rules it out for most of my projects.
comment by shuzchen · 2013-10-04 · in Bluebird – A full-featured, fast promises library for JavaScript -
…wrappers manually, that could be improved. Look into both overloads of [`Promise.promisify`]( https://github.com/petkaantonov/bluebird/blob/master/API.md#... )
comment by esailija · 2013-10-04 · in Bluebird – A full-featured, fast promises library for JavaScript