JavaScript ES6 Promises - Full Playlist

The fundamentals about how JavaScript ES6 Promises work and how you could use them in your code.This is the first in a series of videos about Promises.Next P...

The new Promise.allSettled method

Enjoy the videos and music you love, upload original content, and share it all with friends, family, and the world on YouTube.

How to Ensure that a Function Accepts a Value but not a Promise in TypeScript

How to Ensure that a Function Accepts a Value but not a Promise in TypeScript. Today I had to write a function foo in TypeScript that would accept single argument of type object. Then I had another async function bar that would return object. These were the functions that would be heavily used by other engineers and play important role in our system — “core functions”

Using Promise with Async/Await to get data

Let's take a simple example of calling three functions in series. ... Using Async/Await syntax, a promise-based asynchronous code can be written in a synchronous format ... Promise.resolve( data ) and Promise.reject( errData ).

Mastering Promises

In this article, we will understand what a promise is, what is it doing in the background, and understand its behavior.

Mastering JavaScript Promises

Javascript became popular due to it’s asynchronous nature. Before promises, writing asynchronous code meant writing hugely nested callbacks (callbacks inside callbacks), this meant less intuitive code, longer debugging sessions and huge technical debt.

Level Up Your Asynchronous JavaScript Skills by Implementing a Bluebird-Style Promise.map

Level Up Your Asynchronous JavaScript Skills by Implementing a Bluebird-Style Promise.map. Better asynchronicity.I do a lot of web scraping with Node.js in my work. Usually, you do not want to fire all your API calls in one go, as doing so is likely to overwhelm other people’s servers, trigger their DDoS protection, or worse, take them offline.

Callback vs Promises vs Async Await

Learn fundamental concepts that JavaScript relies on to handle asynchronous operations. These concept includes Callbacks, Promises and the use of Async and Await to handle deferred operations.

Promises, Node, Tedious, Azure SQL. Oh My!

Encapsulating Tedious in a Promise to allow easy asyncronous support to the most used library to accees Azure SQL

JavaScript Promise: Methods Comparison

What are promises and what is the difference between Promise.all, Promise.allSettled, Promise.race and Promise.any?

A Gentle Introduction to JavaScript Promises. I Promise :).

Promises are a fairly new API in JavaScript so we will first look at how asynchronous operations were done before promises. The most common way was to pass in callback functions that were called and ran after the success or failure of the asynchronous function.

Understanding JavaScript: Promises, Async & Await!!

We all know the importance of promises in our life. We even have a special day dedicated to it :) But how well do we know the importance of promises in JavaScript? Well if you don’t know it yet, it’s a great time to know it because they are becoming more and more popular. So what are promises? Let’s try to understand it through an analogy.

Managing asynchronous code in React

we want: To care only about the fulfilled state in our components, to abstract away the pending and rejected state. Here, I am going to show you how to achieve just that and how to structure asynchronous code in a modern way.

Improve Your Node.js Performance With Promise Pools

In Node.js, the typical way to achieve concurrency is by using one of the promise methods — the most common being Promise.all(). Imagine you want to query a database with a list of IDs for a list of users and you want to act on the data returned (e.g. create a new user if the ID didn’t return a user).

JavaScript Asynchronous Operation — Read File Directory with Callback or Promises

JavaScript is a synchronous, blocking, single threaded language. Synchronous single threaded means JavaScript waits for the task to be completed before being able to move on to the next task.

Order of Execution of JavaScript Promises (With Examples)

Confused about the order in which JavaScript promises execute? I was too. Working through some examples and referencing the JavaScript spec helped better my understanding — hopefully it can do the same for you.

What is Callback-Function in JavaScript? How it is Replaced By Promises?

Let us understand term Callback by an real-world example: Suppose, you are calling to your Girlfriend (If you have) and she is busy in another call then she send message to you : “I am busy right now, Call back you later.!!”. After completing her work, she calls you back and this is what call back in JavaScript as well. In this post, we'll discuss What is Callback-Function in JavaScript? How it is Replaced By Promises?

Sequential and Parallel Asynchronous Functions

How to process a collection of asynchronous JavaScript functions either sequentially or in parallel. JavaScript is known for its non-blocking calls using callbacks, promises, and async/await. Occasionally the need will arise to process a collection of non-blocking calls either sequentially or in parallel.

Refactoring Fetch to Async/Await

Clean up your code to make your API requests easier to understand and debug. Async/await is one of the most revolutionary features that has been added to JavaScript in the past few years. It offers an intuitive replacement to the syntactical mess that promises sometimes tend to be. There is nothing wrong with the good old Fetch API, which is made available by default to make ajax requests and more.

Retrying and Exponential Backoff With Promises

When you don’t have an interface for knowing when a remote resource is available, an option to consider is to use exponential backoff rather than to poll that resource until you get a response. In this scenario, let’s mimic the behaviour of a browser and a server. Let’s say the server has an abysmal failure rate of 80%.