
Allow your website to support a user's preferences and easily be switched
I teach people how to be awesome devs.
I have been developing websites professionally since 1999 and have used a number of technologies and watched the evolution of the web since its early days. I write about PHP, Laravel, Tailwind, and topics about improving your career as a developer.
Markdown supported · ⌘↵ to post
Max
This is a great approach. It's the only one I've tried that's actually worked. I just wanted to add one thing. For mobile bf cache, I added a pageshow event listener to the deferred section of script so that the preference would persist. Without it, it wasn't — at least on Android Chrome and Firefox. Thanks again for the awesome tutorial!