Widely available Supported across all major browsers. Safe to use in production.

Browser support

Feature Desktop Mobile
Chrome
Edge
Firefox
Safari
Chrome Android
Safari iOS
71
79
69
12.1
71
12.2
1+Supported (version) Not supported Has note Sub-feature descriptions sourced from MDN Web Docs (CC BY-SA 2.5)

Syntax

JAVASCRIPT
queueMicrotask(() => {
  // function contents here
});

Use cases

  • Using queueMicrotask()

    The queueMicrotask() method of the Window interface

Cautions

  • May not be supported in older browsers.

Implementation notes

  • Some APIs require a secure context (HTTPS) or user activation. Check the requirements before use.