Hey guys,
It really sucks I can’t post the site here (I’ll ask my boss). But I just achieved the infamous 100/100 pagespeed score on a highly dynamic WordPress site with a completely custom theme.
This site had:
\* booking via 3rd party (xola)
\* jQuery
\* A slick slider of awards
\* another 2 slick sliders of 10 or so elements
\* a hero background video
\* cdn
\* 2 youtube videos (both below the fold)
\* 4 google fonts
\* google analytics
\* lots of images
I’ll answer any specific questions you have, but in general this is how I achieved it.
\* google fonts downloaded, served locally
\* Separated css into pagespecific files, and inline’d those on a per page basis
\* inlined style.css via php and removed the <link> element for it
\* loaded all javascript deferred, even jquery, in the footer, all js wrapped in DOMContentReady
\* for bookings, the 3rd party booking script was loaded on click of a book now button, one time, then available thereafter
\* google analytics wasn’t loaded until user interaction (mousemove, touchstart)
\* youtube videos were loaded with a facade until they were in the viewport using intersection observer
\* all images were webp format and appropriate sized
\* Connected the cdn via w3 total cache plugin (bunny cdn)
\* removed unnecessary wordpress scripts and styles
\* removed jquery-migrate (didn’t need it)
\* added font-display: swap to all fonts
All this got me a 90 on mobile and a 99 on desktop with the CDN connected. Without the CDN connected, I got a 100/100.
So I investigated and my LCP’s were headings.. just text. Turns out the font was being served from the CDN. So I had w3 total cache exclude fonts (and jquery for good measure) from being served by the cdn, and voila!
100/100.
[ad_2]