Registering scripts with `async` and `defer` attributes in WordPress 6.3

WordPress 6.3 introduces support for registering scripts with async and defer attributes as part of an enhancement to core’s existing Scripts API. This addresses a long-standing Trac ticket, and adds the ability to define a loading strategy for scripts. Supported strategies are as follows:

This post was originally published on Make Core by Simon Dowdles.

Follow us

Don't be shy, get in touch. We love meeting interesting people and making new friends.