{"id":18790867,"date":"2026-01-19T13:12:28","date_gmt":"2026-01-19T13:12:28","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/console-errors-with-defer-render-blocking-javascript\/"},"modified":"2026-01-19T13:12:28","modified_gmt":"2026-01-19T13:12:28","slug":"console-errors-with-defer-render-blocking-javascript","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/console-errors-with-defer-render-blocking-javascript\/","title":{"rendered":"Console Errors with Defer Render-blocking JavaScript"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Hello,<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I am using your plugin to defer render-blocking JavaScript, and I have excluded the following scripts from deferral:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>\/wp-includes\/js\/dist\/vendor\/moment.min.js<br \/>\/themes\/woodmart\/js\/scripts\/wc\/updateCartFragmentsFix.js<br \/>\/wp-includes\/js\/jquery\/jquery.min.js<br \/>\/wp-includes\/js\/jquery\/jquery-migrate.min.js<br \/>\/themes\/woodmart\/js\/scripts\/global\/helpers.min.js<br \/>\/themes\/woodmart\/js\/scripts\/wc\/woocommerceNotices.min.js<br \/>\/themes\/woodmart\/js\/scripts\/global\/scrollBar.min.js<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Despite these exclusions, I am seeing the following errors in the browser console:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">wp-data-js-after:6<br \/>Uncaught TypeError: Cannot read properties of undefined (reading &#8216;use&#8217;)<br \/>at wp-data-js-after:6:3<br \/>at wp-data-js-after:7:4<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">wp-date-js-after:2<br \/>Uncaught TypeError: Cannot read properties of undefined (reading &#8216;setSettings&#8217;)<br \/>at wp-date-js-after:2:9<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I attempted to exclude the directories responsible for these inline scripts (<code>wp-data.js<\/code>, <code>wp-date.js<\/code>), but when I do, the plugin suggests additional directories that also need to be excluded. I am unsure which ones are critical to maintain proper WordPress core functionality.<\/p>\n\n\n\n<ol>\n<li>Could you advise exactly which scripts\/directories need to be excluded from Defer Render-blocking so that these errors (<code>wp-data-js-after<\/code> and <code>wp-date-js-after<\/code>) are resolved without breaking WordPress, Gutenberg, or WooCommerce functionality?<\/li>\n\n\n\n<li>Is there a safe list of core WordPress scripts that must always load synchronously?<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">Thank you in advance for your assistance!<\/p>\n","protected":false},"template":"","class_list":["post-18790867","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/18790867","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/18790867\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=18790867"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}