Delayed JavaScript Broke a WordPress Mobile Menu Despite Strong PageSpeed Scores

A WordPress site scoring in the high 90s on mobile PageSpeed Insights had a hamburger menu that failed to respond reliably when tapped on a real phone. The site used the Kadence theme and LiteSpeed Cache, with JavaScript deferral enabled to reduce initial page load work. Desktop and emulated mobile checks did not reproduce the issue, but bypassing LiteSpeed's Page Optimization layer made the menu work again. The author then excluded the Kadence navigation scripts from delayed loading, noting these filename-based exclusions depend on the specific theme and setup. The author stresses this was not a controlled experiment and that the exact cause was not fully confirmed.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)
Log in to join the discussion and vote.
Log in