- Server Side development with Node.js and Koa.js Quick Start Guide
- Olayinka Omole
- 99字
- 2021-06-10 18:57:12
What is async… await?
Asynchronous functions are functions that work asynchronously. They return a Promise class implicitly and can run concurrently. We will be discussing two major ways to define asynchronous functions. These include the following:
- Using the native Promise class
- Using the modern Async keyword
The await keyword is used inside an asynchronous function to resolve a promise. Async and await are usually used together for managing the control of flow in a modern asynchronous JavaScript application. Koa relies heavily on async.. await to avoid callback hell and provide a more convenient method for handling errors.
推薦閱讀
- INSTANT OpenCV Starter
- Spring技術內幕:深入解析Spring架構與設計
- 深入淺出Java虛擬機:JVM原理與實戰
- MySQL 8 DBA基礎教程
- Django:Web Development with Python
- Python漫游數學王國:高等數學、線性代數、數理統計及運籌學
- Getting Started with Laravel 4
- Visual C#.NET Web應用程序設計
- Getting Started with Nano Server
- Ext JS 4 Plugin and Extension Development
- 軟硬件綜合系統軟件需求建模及可靠性綜合試驗、分析、評價技術
- Pandas入門與實戰應用:基于Python的數據分析與處理
- TensorFlow+Keras深度學習算法原理與編程實戰
- GitHub Essentials
- Scratch趣味編程:邏輯思維培養與訓練