Introducing Better Resource Hints, a Performance-Enhancing Plugin for WordPress
Interesting. Thanks for sharing!
Thanks and shared!
First time hearing about rel=preload. Sometimes jQuery script is inlined in the dom when jQuery is being loaded in the footer. The rel=preload could keep footer asset loading in play while making sure inline JS has it’s dependencies met.
Thanks, I appreciate that! Yes, it has some nice advantages over using other tricks like applying an asyn attribute to a script. One downside is that browser support isn’t as great as it could be, but thankfully, there’s no negative consequence to using it for JS anyway. If preloading isn’t supported, it’s just skipped over and nothing breaks.
Played around with the code on the dashboard and modified it a bit(yes i know it is not recommended just did it for fun). tested it on the landing pages of the wordpress admin.with only 2 active widgets. it does help. then i realize that the dashboard in of it self is really slow because of a lot of factors. dashboard discussion aside rel=preload + defer is better than async + defer.
Yes! And it’s worth noting that preloading, async, and defer are all different mechanisms meant for different purposes. Glad to see browser support is good and growing for all of these tactics.
Yes! I actually included loadCSS and CSS preloading in my plugin Better Resource Hints, along with preloading, prefetching, and preconnecting. For the front end, it’s a quick way to implement all of these enhancements on your site without bootstrapping it all yourself: