Home › Forums › WoodMart support forum › Website’s mobile menu takes time to load
Website’s mobile menu takes time to load
- This topic has 3 replies, 2 voices, and was last updated 2 weeks, 6 days ago by
Artem Temos.
-
AuthorPosts
-
September 17, 2025 at 3:25 pm #686829
admin-3814ParticipantWe are currently using the Woodmart theme along with the WP Rocket plugin on our website.
I have enabled both the “Delay JavaScript Execution” and “Defer JavaScript” options in WP Rocket. Additionally, in the theme settings, I’ve activated the “WP Rocket Delay JS Exclusions” option to get an exclusion list for the theme.
However, we’re experiencing an issue with the mobile menu. When a user clicks the menu icon immediately after the page loads—without interacting with the page (e.g., scrolling)—the menu takes time to appear. But, if the user interacts with the page first and click on the menu icon, the menu opens much faster.Upon investigation, I found that the function responsible for triggering the mobile menu is loaded only after all delayed scripts have loaded.
Could you please review this and suggest a solution to fix the mobile menu loading delay?
September 17, 2025 at 3:43 pm #686836
Artem TemosKeymasterHello
This behavior is expected due to the “Delay JavaScript Execution” feature in WP Rocket. This option postpones loading certain JavaScript files until the user interacts with the page, such as scrolling or clicking. As a result, when the mobile menu icon is clicked immediately after page load without prior interaction, all scripts are loading, causing the delay.
Regards
September 17, 2025 at 3:52 pm #686838
admin-3814ParticipantWe cannot disable the “Delay JavaScript Execution” as it will affect the website’s performance. Is there any solution to fix the delay? Or could you please specify which scripts should be excluded from the “Delay JavaScript Execution” to ensure the menu functions correctly without any delay?
September 17, 2025 at 4:52 pm #686856
Artem TemosKeymasterHello,
The actual lag is caused by the “delay option” itself. When you click on anything on your page, it begins loading all the scripts simultaneously. This is why you experience this lag. In essence, you intentionally create this lag by enabling the “Delay JS” option. While this option improves the initial loading time (since scripts aren’t loaded), it also adds some waiting time on the first click. Excluding scripts doesn’t make any difference because there are still a lot of files to load. You need to decide whether you load all the scripts initially or you enable Delayed JS.
Kind Regards
-
AuthorPosts
Tagged: woodmart mobile menu
- You must be logged in to create new topics. Login / Register