async / await
Term side of the Card
Topic: Syntax
Unit title: async / await
Categories: Syntax, Keyword
Explanation side of the Card
Explanation: The keywords used to handle asynchronous code in JavaScript, making it easier to work with promises. The `async` is used to define functions that return a `Promise` object and `await` pauses the execution of code within the function until the promise is resolved or rejected, allowing for more structured code, while other code continues executing.
Browser compatibility:
- The chrome browser supports this feature starting from version 55
- The edge browser supports this feature starting from version 15
- The firefox browser supports this feature starting from version 52
- The safari browser supports this feature starting from version 10.1
Availability: