JavaScript Professional — Medium
Key points
- The await keyword is used to handle asynchronous operations in JavaScript.
- The Promise.reject() method creates a rejected Promise with a specified reason.
- The catch block is used to handle any errors that occur during the Promise execution.
Ready to go further?
Related questions
