We changed our privacy policy. Read more.

Questions tagged [promise]

"Promises" are a particular tactic for deferred computing, suitable for several styles of concurrency: thread and event loop concurrency for local computation, and both synchronous and asynchronous remote messaging.

Filter by
Sorted by
Tagged with
4
votes
1answer
516 views

Read files from a directory using Promises

Using javascript functions and the old way of doing things I wrote a piece of code to copy the first file in a directory to a file Test. ...
3
votes
1answer
120 views

Implementing `Promise.all()`

I took a stab at implementing Promise.all(): ...
3
votes
0answers
437 views

Blocking Promise-driven queues with ECMAScript's async/await and generators

I implemented an AsyncQueue, whose dequeue() operation returns a Promise. The ...
3
votes
2answers
311 views

Promise.jsm demo of Promise.all and Promise.defer

I created this demo example for MDN documentation to show how to use Promise.all and Promise.defer in user created promise. I ...
0
votes
2answers
66 views

Achieve error differentiation in Promises

Background I have a REST API using MongoDB, Node.js and Express that makes a request to my NoSQL DB and depending on different results, I want to differentiate which error I send the customer. ...