JS Asynchronous: 3. Sử dụng Async await

Author: - Posted: 02/01/21 - Update: 02/01/21

1. Async await là gì

- Hàm async luôn trả về 1 Promise
- Await chính là promise.then(res=>...). Kết quả của await chính là res của then trong promise

Demo sử dụng Asyn await để Get Data