<span>Since promises were added to JavaScript in 2015, they have become an integral part of the language. A good understanding of how promises work is more important than ever in becoming a proficient JavaScript developer. This book begins by explaining the basic concepts behind promises, including
Understanding JavaScript Promises
โ Scribed by Nicholas C Zakas
- Publisher
- Lulu.com
- Year
- 2022
- Tongue
- English
- Leaves
- 90
- Category
- Library
No coin nor oath required. For personal study only.
โฆ Synopsis
Since promises were added to JavaScript in 2015, they have become an integral part of the language. A good understanding of how promises work is more important than ever in becoming a proficient JavaScript developer. This book begins by explaining the basic concepts behind promises, including what they are, how to use them, and how to create your own. You'll then build upon these basic concepts to learn how to chain promises together and how to respond to multiple promises at once. Once you've learned these advanced concepts, you'll move on to learn how promises work with async functions and how to track unhandled promise rejections. All of the concepts discussed are grounded in real world examples so you learn not just how to use a particular technique, but also why and when to use it. It doesn't matter if you're writing JavaScript for web browsers, Node.js, or Deno, this book will teach you everything you need to know about promises.
โฆ Table of Contents
Table of Contents
Introduction
About This Book
Acknowledgments
About the Author
Disclaimer
1. Promise Basics
The Promise Lifecycle
Creating New (Unsettled) Promises
Creating Settled Promises
Summary
2. Chaining Promises
Catching Errors
Using finally() in Promise Chains
Returning Values in Promise Chains
Returning Promises in Promise Chains
Summary
3. Working with Multiple Promises
The Promise.all() Method
The Promise.allSettled() Method
The Promise.any() Method
The Promise.race() Method
Summary
4. Async Functions and Await Expressions
Defining Async Functions
What Makes Async Functions Different
Summary
5. Unhandled Rejection Tracking
Detecting Unhandled Rejections
Web Browser Unhandled Rejection Tracking
Node.js Unhandled Rejection Tracking
Summary
Final Thoughts
Download the Extras
Support the Author
Help and Support
Follow the Author
๐ SIMILAR VOLUMES
<div><p><strong>Build fully functional web applications using promises, the new standard in JavaScript</strong></p> <h2>About This Book</h2> <ul> <li>Integrate JavaScript Promises into your application by mastering the key concepts of the Promises API</li> <li>Replace complex nested callbacks in
<div><p>Asynchronous JavaScript is everywhere, whether youโre using Ajax, AngularJS, Node.js, or WebRTC. This practical guide shows intermediate to advanced JavaScript developers how Promises can help you manage asynchronous code effectivelyโincluding the inevitable flood of callbacks as your codeba
<div><p>Asynchronous JavaScript is everywhere, whether youโre using Ajax, AngularJS, Node.js, or WebRTC. This practical guide shows intermediate to advanced JavaScript developers how Promises can help you manage asynchronous code effectivelyโincluding the inevitable flood of callbacks as your codeba
<div><p>Asynchronous JavaScript is everywhere, whether youโre using Ajax, AngularJS, Node.js, or WebRTC. This practical guide shows intermediate to advanced JavaScript developers how Promises can help you manage asynchronous code effectivelyโincluding the inevitable flood of callbacks as your codeba
<p><b>Discover and explore the world of promises, one of JavaScript's most powerful concepts</b></p> <h2>About This Book</h2><ul><li>Look into Promises in-depth, learn how they are utilized in different modern web programming technologies, and gain the knowledge and confidence to apply them in your