Navigation Off Canvas + WP Rocket

Hey folks,

I’ve got a bunch of sites on Pro/X and have run into this issue handful of times. Normally, I simply turn off WP Rocket CSS / JS compression/minification/etc… but I’d really like to have a standard way to make this work and get WP rocket to function! (Love those 90s on GTmetrix…)

So, when using the Pro Header and the Navigation Off Canvas Element + WP Rocket (with all File Optimization settings on), you see this glitch on mobile where the off-canvas menu slides off screen on page load.

When you turn off all the CSS / JS stuff on WP Rocket, the issue disappears. I’m assuming this is because WP Rocket is compressing all JS / CSS into a single file that then gets loaded in incorrectly.

What file paths would exclude the Header JS/CSS? I’m guessing this is the proper approach?

Currently, I’m using Pro Renew (and most frequently use Renew). The site is https://onyxcool.com/, but the client has some big meetings/events/etc. over the next few weeks so I can’t show you the issue live, unfortunately.

Does the above make sense? This post sounds as though it was having the same issue.

Thanks!

Luke

Hi Luke,

The JS/CSS file of Pro theme is not separated for the header section and the theme loads already minified files. I suggest that you exclude the file below from WP Rocket:

wp-content/themes/pro/cornerstone/assets/dist/js/site/cs.2f77946.js

Please use an FTP connection to go to the folder in question and make sure that you write down the file name as it might be different depending on the version of the theme that you use.

Thank you.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.