Title: Defer Render-blocking JavaScript also blocks jQuery for WooCommerce
Last modified: January 20, 2025

---

# Defer Render-blocking JavaScript also blocks jQuery for WooCommerce

 *  [thesunflowers](https://wordpress.org/support/users/thesunflowers/)
 * (@thesunflowers)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/defer-render-blocking-javascript-also-blocks-jquery-for-woocommerce/)
 * Hello,
 * I recently experienced an issue with this plugin on a site using **WooCommerce**,**
   WooCommerce Bookings** and **WooCommerce Gift Cards**.
 * This was due to the fact that in the Frontend JavaScript settings, we had **Defer
   Render-blocking JavaScript** turned on. This was causing an error in the browser
   console where WooCommerce was complaining that **jQuery** was not defined. This
   meant our booking forms and some of our checkout was not rendering properly, 
   or at all.
 * We’ve had this setting turned on for a while, it was only detected as an issue
   for us in the last couple of days, so I’m not sure if **WordPress** was taking
   too long to load **jQuery** that the **Speed Optimizer** plugin decided to defer
   it?
 * When we turned this setting off, it all worked as normal.
 * We’re also using SiteGround Hosting, so assume that there was no conflict with
   how our hosting is functioning.
 * While we’ve found a workaround by turning that setting off, I’d be interested
   to know if that’s the expected behaviour of the **Defer Render-blocking JavaScript**
   setting, or if there’s an (occasional or consistent) error in how it handles 
   this on WooCommerce sites?

Viewing 1 replies (of 1 total)

 *  Plugin Support [Georgi Ganchev](https://wordpress.org/support/users/georgiganchev/)
 * (@georgiganchev)
 * [1 year, 4 months ago](https://wordpress.org/support/topic/defer-render-blocking-javascript-also-blocks-jquery-for-woocommerce/#post-18254045)
 * Hello [@thesunflowers](https://wordpress.org/support/users/thesunflowers/) ,
 * It seems that some scripts on your website may not work well with the “Defer 
   Render-blocking JavaScript” option in SiteGround Optimizer. This feature is designed
   to help browsers prioritize loading and displaying immediately visible resources,
   while deferring those not needed for the initial page load. However, it can cause
   issues with scripts that need to execute in a specific order, which is likely
   the problem here. You can resolve this by using the “Exclude from Deferral of
   Render-blocking JS” option to exclude the problematic scripts: [SiteGround Tutorial](https://www.siteground.com/tutorials/wordpress/sg-optimizer/frontend-optimization/#Defer_Render-blocking_JavaScript).
   If the script is not present in the dropdown, it might be due to the way it is
   loaded by one of your plugins in such case you can use [the custom filters](https://www.siteground.com/tutorials/wordpress/speed-optimizer/custom-filters/)
   to exclude it’s handle.
 * Alternatively, you might consider keeping this feature disabled.
 * Best regards,
   Georgi GanchevSiteGround.com

Viewing 1 replies (of 1 total)

The topic ‘Defer Render-blocking JavaScript also blocks jQuery for WooCommerce’ 
is closed to new replies.

 * ![](https://ps.w.org/sg-cachepress/assets/icon-256x256.gif?rev=2971889)
 * [Speed Optimizer - The All-In-One Performance-Boosting Plugin](https://wordpress.org/plugins/sg-cachepress/)
 * [Support Threads](https://wordpress.org/support/plugin/sg-cachepress/)
 * [Active Topics](https://wordpress.org/support/plugin/sg-cachepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/sg-cachepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/sg-cachepress/reviews/)

## Tags

 * [jquery](https://wordpress.org/support/topic-tag/jquery/)

 * 1 reply
 * 2 participants
 * Last reply from: [Georgi Ganchev](https://wordpress.org/support/users/georgiganchev/)
 * Last activity: [1 year, 4 months ago](https://wordpress.org/support/topic/defer-render-blocking-javascript-also-blocks-jquery-for-woocommerce/#post-18254045)
 * Status: not resolved