Top "Promise" questions

Promises are a 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.

How do I await multiple promises in-parallel without 'fail-fast' behavior?

I'm using async/await to fire several api calls in parallel: async function foo(arr) { const results = await Promise.all(…

javascript asynchronous promise async-await
Native Support for Promises in Node.js

Is there native support for promises in current versions of Node.js? Node.js uses the V8 engine. This JavaScript …

javascript node.js promise
How to find which promises are unhandled in Node.js UnhandledPromiseRejectionWarning?

Node.js from version 7 has async/await syntactic sugar for handling promises and now in my code the following warning …

node.js promise async-await warnings unhandled-exception
javascript, promises, how to access variable this inside a then scope

I want to be able to call a function inside the .then scope, and for that I use the this.…

javascript promise angular-promise
How to promisify Node's child_process.exec and child_process.execFile functions with Bluebird?

I'm using the Bluebird promise library under Node.js, it's great! But I have a question: If you take a …

javascript node.js promise bluebird
How to check if a Promise is pending

I have this situation in which I would like to know what the status is of a promise. Below, the …

javascript promise ecmascript-6 es6-promise
How to catch uncaught exception in Promise

Is there any way to globally catch all exceptions including Promise exceptions. Example: window.onerror = function myErrorHandler(errorMsg, url, lineNumber) { …

javascript exception promise
How to add delay to promise inside then

fetch() { return axios.get('/rest/foo') //.then(response => {throw new Error(response)}) // Uncomment to test network error //.then( &…

javascript asynchronous callback promise
Angular2 Observable and Promise

I started using Angular2 Observable, but I can't find something similar to .then that I used with Promises. This is …

angular promise rxjs observable
Are there still reasons to use promise libraries like Q or BlueBird now that we have ES6 promises?

After Node.js added native support for promises, are there still reasons to use libraries like Q or BlueBird? For …

javascript node.js promise q bluebird