Daniel's Notes
  • Home
  • About
Subscribe

Code

A collection of 1 post
Make Alpine 3 support legacy browsers
Code

Make Alpine 3 support legacy browsers

Today I learned that AlpineJS 3.x uses queueMicrotask –  and that that’s an API not supported in Firefox < 69 and Safari < 12.1 (see caniuse for full support information). Luckily, this can easily be polyfilled: if (typeof window.queueMicrotask !== "function") { window.queueMicrotask = function (callback) { Promise.resolve() .then(callback) .catch(
Apr 7, 2022
Daniel's Notes © 2023
  • Sign up
Powered by Ghost