We learn about Promises in Javascript. They allow us to deal with events that happen asynchronously in the future. This is one of the superpowers of using Javascript for our programs and is a common feature in many other languages albeit in slightly different ways.
We will see Promises show up in almost everything we do when we get to front-end and back-end web development, but it appears everywhere else as well.
This video deals with "vanilla" Promises. In a future video we'll get to async/await syntax that simplifies how we can use these promise chains.
This is part of a series where we go over Javascript in depth to learn programming concepts as well as web development: • Javascript In Depth
Chapters:
00:00 Introduction
01:12 Promise Concepts
11:29 Promise States
12:55 Promise Analogy
21:39 Promise Flow
22:20 Creating a new Promise
26:04 Promise Constructor Code
33:12 Fulfilled Promises
35:24 Fulfilled Promise Code
38:39 Rejected Promises
39:42 Rejected Promise Code
43:00 Promise Chaining
48:55 Next Steps
📦 Github Repository with the notes and exercise code+solutions: github.com/Nooder/javascript-...
💬 Come join us on Discord to chat with a like-minded community about tech and learning: / discord
🏅Support the channel and content through Super Thanks, Channel Memberships, or on Patreon: / techwithnader
6 авг 2024