[wp-trac] [WordPress Trac] #54172: Replace frontend jQuery usage with vanilla JS in Twenty Fifteen
WordPress Trac
noreply at wordpress.org
Thu Sep 23 19:11:38 UTC 2021
#54172: Replace frontend jQuery usage with vanilla JS in Twenty Fifteen
---------------------------+-----------------------------
Reporter: flixos90 | Owner: flixos90
Type: enhancement | Status: assigned
Priority: normal | Milestone: Awaiting Review
Component: Bundled Theme | Version:
Severity: normal | Keywords: needs-patch
Focuses: javascript |
---------------------------+-----------------------------
Using jQuery for a few simple JS interactions in WordPress themes is a
common performance problem, which is in most cases relatively
straightforward to address: Vanilla JavaScript has for the better part of
a decade included enough APIs that work across all popular browsers so
that the remaining benefits of jQuery are around a few utility functions,
that could be re-implemented in a few lines of code. Using jQuery for such
simple use-cases results in around 80% more JS code being loaded in the
frontend.
This ticket focuses on removing jQuery as a **frontend** dependency for
Twenty Fifteen - specifically the frontend, as for example in the
Customizer jQuery is loaded anyway (and performance is a bit less of a
concern there).
Also see #54171, which does the same for Twenty Twelve.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/54172>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list