3 ms·
The comparison page highlights that Zone.js is better than promises because of long stack traces [1], but most promise implementations already have that [2]. I
by munro 12y ago
The comparison page highlights that Zone.js is better than promises because of long stack traces [1], but most promise implementations already have that [2]. I'm confused, that seems to be the only comparison to promises.
Edit: Conceptually it seems the same as promises. The main difference seems to be that they've added hooks [3] into the pipeline, and they duck punch the core API to intercept errors. Bluebird has solved this without duck punching using `Promise.promisifyAll(require("fs"))` [4]. I would love to see a write up on Zone.js's forks, because the article could of trivially been rewriten to use promises.
[1] http://strongloop.com/strongblog/comparing-node-js-promises-trycatch-zone-js-angular/ http://strongloop.com/strongblog/comparing-node-js-promises-...
[2] https://github.com/kriskowal/q#long-stack-traces https://github.com/kriskowal/q#long-stack-traces
[3] https://github.com/btford/zone.js/#zonefork https://github.com/btford/zone.js/#zonefork
[4] https://github.com/petkaantonov/bluebird https://github.com/petkaantonov/bluebird
- piscisaureus 12y agoNote that the comparison page doesn't have the "zone" library we just announced on it. Zone.js is conceptually a bit different and it targets browsers.