Exclude global JS on specific pages

Hi Team,

I was wondering if there was an easy way to stop WP from loading the content of the global JS on certain pages. I have two pages in which I do NOT want the contents of global JS to run. I’d prefer to avoid adding the JS to every page except the two in question and deleting it from my global JS, as it is a relatively large site in which each additional page will need the global JS to work properly.

Any feedback on how to proceed would be greatly appreciated. Thanks!

Hello Hunter,

Thanks for writing in!

It’s not really a good idea to exclude JS files on pages as it might cause conflicts in the builder and functioning of website and that particular page. However, if you would like please refer following resource:

Please note that any issues coming up because of this changes in question will fall outside the scope of support we can offer.

Thanks.

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