-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Fix: Limit loading legacy single product scripts #60223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: trunk
Are you sure you want to change the base?
Conversation
Testing GuidelinesHi @kmanijak , Apart from reviewing the code changes, please make sure to review the testing instructions (Guide) and verify that relevant tests (E2E, Unit, Integration, etc.) have been added or updated as needed. Reminder: PR reviewers are required to document testing performed. This includes:
|
📝 WalkthroughWalkthroughThis change refines the loading behavior of legacy WooCommerce single product scripts and styles by restricting their enqueueing to legacy/classic blocks and templates only. It removes legacy script loading for block themes and introduces new methods to conditionally enqueue or dequeue these assets. Additionally, array syntax is standardized to long-form Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant WP_Block_Render
participant ClassicTemplate/ProductImageGallery Block
participant WC_Frontend_Scripts
participant BlockTemplatesController
User->>WP_Block_Render: Requests single product page
WP_Block_Render->>ClassicTemplate/ProductImageGallery Block: Render block
ClassicTemplate/ProductImageGallery Block->>WC_Frontend_Scripts: Conditionally enqueue legacy scripts/styles
WP_Block_Render->>BlockTemplatesController: wp_enqueue_scripts hook triggers
BlockTemplatesController->>WC_Frontend_Scripts: Dequeue legacy scripts if block theme
WP_Block_Render->>User: Return rendered page
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~15–20 minutes Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: .coderabbit.yml 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (24)
✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
Test using WordPress PlaygroundThe changes in this pull request can be previewed and tested using a WordPress Playground instance. Test this pull request with WordPress Playground. Note that this URL is valid for 30 days from when this comment was last updated. You can update it by closing/reopening the PR or pushing a new commit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I followed the steps and can confirm the dependencies are loaded as expected, especially:
- Product Image Gallery dependencies (e.g. flexslider or photoswipe) are loaded only with Classic block or with Product Image Gallery,
single-product.js
is loaded with Classic block or when classic Product Image Gallery or Product Details are in use.
Great job! 💪
Side question, I see you're changing []
into array()
- is that done automatically by your linter or you do it manually? If so, why? Is there any benefit of array()
over []
?
Yeah, it's auto-formatted by my editor. I need to see why it didn't follow our ruleset. I deleted that change manually probably three times for this PR 😅 , let me remove it. |
…ich is for classic themes
0a5861d
to
20d11ad
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php (2)
30-31
: Revert array syntax to align with project standards.The change from
[]
toarray()
contradicts the established WooCommerce coding standards. Per the PR objectives, this was unintended auto-formatting.- return array( 'query', 'queryId', 'postId' ); + return [ 'query', 'queryId', 'postId' ];
48-73
: LGTM! Comprehensive legacy asset management.The method properly handles legacy script requirements:
- Enqueues all necessary scripts (zoom, flexslider, photoswipe)
- Includes required styles (photoswipe-default-skin)
- Adds photoswipe template to footer
- Enables required filters for zoom, photoswipe, and flexslider functionality
The intentional duplication with
ClassicTemplate.php
is well-documented and aligns with the PR's independence strategy for legacy blocks.However, consider the array syntax consistency:
- add_action( 'wp_enqueue_scripts', [ $this, 'enqueue_legacy_assets' ], 20 ); + add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_legacy_assets' ), 20 );
📜 Review details
Configuration used: .coderabbit.yml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (6)
plugins/woocommerce/changelog/60223-fix-remove-legacy-scripts-loading
(1 hunks)plugins/woocommerce/includes/class-wc-frontend-scripts.php
(1 hunks)plugins/woocommerce/src/Blocks/BlockTemplatesController.php
(1 hunks)plugins/woocommerce/src/Blocks/BlockTypes/ClassicTemplate.php
(3 hunks)plugins/woocommerce/src/Blocks/BlockTypes/ProductDetails.php
(2 hunks)plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (4)
- plugins/woocommerce/changelog/60223-fix-remove-legacy-scripts-loading
- plugins/woocommerce/includes/class-wc-frontend-scripts.php
- plugins/woocommerce/src/Blocks/BlockTypes/ProductDetails.php
- plugins/woocommerce/src/Blocks/BlockTypes/ClassicTemplate.php
🧰 Additional context used
📓 Path-based instructions (2)
**/*.{php,js,jsx,ts,tsx}
📄 CodeRabbit Inference Engine (.cursor/rules/code-quality.mdc)
**/*.{php,js,jsx,ts,tsx}
: Guard against unexpected inputs
Sanitize and validate any potentially dangerous inputs
Ensure code is backwards compatible
Write code that is readable and intuitive
Ensure code has unit or E2E tests where applicable
Files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
**/*.{php,js,ts,jsx,tsx}
⚙️ CodeRabbit Configuration File
**/*.{php,js,ts,jsx,tsx}
: Don't trust that extension developers will follow the best practices, make sure the code:
- Guards against unexpected inputs.
- Sanitizes and validates any potentially dangerous inputs.
- Is backwards compatible.
- Is readable and intuitive.
- Has unit or E2E tests where applicable.
Files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
🧠 Learnings (14)
📓 Common learnings
Learnt from: ralucaStan
PR: woocommerce/woocommerce#58782
File: plugins/woocommerce/client/blocks/assets/js/base/utils/render-frontend.tsx:0-0
Timestamp: 2025-06-16T16:12:12.148Z
Learning: For WooCommerce checkout blocks, lazy loading was removed in favor of direct imports to prevent sequential "popping" effects during component loading. This approach prioritizes user experience over code splitting, with minimal bundle size impact and improved performance (1.7s to 1.1s speed score improvement). The checkout flow benefits from having all components load together rather than incrementally.
Learnt from: samueljseay
PR: woocommerce/woocommerce#58716
File: plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/iapi-frontend.ts:83-101
Timestamp: 2025-06-17T07:07:53.443Z
Learning: In WooCommerce blocks, when porting existing code patterns that have known issues (like parseInt truncating decimal money values), maintain consistency with existing implementation rather than making isolated fixes. The preference is for systematic refactoring approaches (like broader Dinero adoption) over piecemeal changes.
Learnt from: jorgeatorres
PR: woocommerce/woocommerce#59675
File: .github/workflows/release-bump-as-requirement.yml:48-65
Timestamp: 2025-07-15T15:39:21.856Z
Learning: In WooCommerce core repository, changelog entries for all PRs live in `plugins/woocommerce/changelog/` directory and are processed during releases, not at the repository root level.
Learnt from: lysyjan
PR: woocommerce/woocommerce#59632
File: packages/js/email-editor/src/layouts/flex-email.tsx:116-122
Timestamp: 2025-07-14T10:41:46.200Z
Learning: In WooCommerce projects, formatting suggestions should respect the project's Prettier configuration and linting rules. Changes that would break the lint job should be avoided, even if they appear to improve readability.
Learnt from: opr
PR: woocommerce/woocommerce#0
File: :0-0
Timestamp: 2025-06-20T17:38:16.565Z
Learning: WooCommerce legacy JavaScript files in plugins/woocommerce/client/legacy/js/ must use older JavaScript syntax and cannot use modern features like optional chaining (?.) due to browser compatibility requirements. Explicit null checking with && operators should be used instead.
Learnt from: NeosinneR
PR: woocommerce/woocommerce#0
File: :0-0
Timestamp: 2025-06-26T14:25:08.421Z
Learning: In WooCommerce transactional emails, product images have historically had display issues due to lazy loading attributes being applied, which email clients cannot process since they don't execute JavaScript. This issue existed in both old and new email templates, but became more visible with the new email template system. The fix involves preventing lazy loading on attachment images specifically during email generation by adding skip classes and data attributes.
Learnt from: Aljullu
PR: woocommerce/woocommerce#58809
File: plugins/woocommerce/src/Blocks/BlockTypes/ProductButton.php:222-225
Timestamp: 2025-06-13T17:11:13.732Z
Learning: In `plugins/woocommerce/src/Blocks/BlockTypes/ProductButton.php`, the team intentionally relies on toggling the `disabled` CSS class (via `data-wp-class--disabled`) instead of binding the `disabled` attribute, to mirror the behavior of the classic WooCommerce template.
Learnt from: Aljullu
PR: woocommerce/woocommerce#59370
File: plugins/woocommerce/client/blocks/assets/js/blocks/product-gallery/style.scss:236-243
Timestamp: 2025-07-03T10:09:20.635Z
Learning: In WooCommerce blocks CSS, prefer using standard CSS properties like `scrollbar-width` over vendor-specific prefixes when the standard property has good browser support. As of late 2024, `scrollbar-width` is widely supported across all major browsers and doesn't require WebKit-specific workarounds.
Learnt from: dinhtungdu
PR: woocommerce/woocommerce#59900
File: plugins/woocommerce/client/blocks/assets/js/blocks/product-filters/inner-blocks/attribute-filter/inspector.tsx:0-0
Timestamp: 2025-07-24T05:37:00.907Z
Learning: The DisplayStyleSwitcher component in plugins/woocommerce/client/blocks/assets/js/blocks/product-filters/components/display-style-switcher/index.tsx has been updated so that its onChange prop accepts only a string type (not string | number | undefined), eliminating the need for type assertions when using this component.
Learnt from: samueljseay
PR: woocommerce/woocommerce#59051
File: plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/mini-cart-contents/inner-blocks/mini-cart-footer-block/index.tsx:66-70
Timestamp: 2025-06-23T05:47:52.696Z
Learning: For WooCommerce mini-cart blocks in plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/, the standardized conditional pattern for experimental features should be `if ( isExperimentalMiniCartEnabled() ) { blockSettings.save = () => <InnerBlocks.Content />; }` - defaulting to the traditional Save component and only overriding when the experimental feature is enabled.
Learnt from: ralucaStan
PR: woocommerce/woocommerce#58782
File: plugins/woocommerce/client/blocks/assets/js/base/components/cart-checkout/product-details/style.scss:21-26
Timestamp: 2025-06-13T15:24:45.923Z
Learning: In WooCommerce blocks, bold styling for `.wc-block-components-product-details__name` should be scoped only to the Cart block (`.wc-block-cart__main`); on the Checkout block, product names are not bold because prices are highlighted instead.
Learnt from: nerrad
PR: woocommerce/woocommerce#60176
File: plugins/woocommerce/client/legacy/css/admin.scss:9088-9105
Timestamp: 2025-08-04T00:21:51.440Z
Learning: WooCommerce is currently in the midst of an admin redesign project, so temporary/short-term CSS solutions for admin pages are preferred over long-term refactoring when addressing immediate needs.
📚 Learning: in `plugins/woocommerce/src/blocks/blocktypes/productbutton.php`, the team intentionally relies on t...
Learnt from: Aljullu
PR: woocommerce/woocommerce#58809
File: plugins/woocommerce/src/Blocks/BlockTypes/ProductButton.php:222-225
Timestamp: 2025-06-13T17:11:13.732Z
Learning: In `plugins/woocommerce/src/Blocks/BlockTypes/ProductButton.php`, the team intentionally relies on toggling the `disabled` CSS class (via `data-wp-class--disabled`) instead of binding the `disabled` attribute, to mirror the behavior of the classic WooCommerce template.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: the displaystyleswitcher component in plugins/woocommerce/client/blocks/assets/js/blocks/product-fil...
Learnt from: dinhtungdu
PR: woocommerce/woocommerce#59900
File: plugins/woocommerce/client/blocks/assets/js/blocks/product-filters/inner-blocks/attribute-filter/inspector.tsx:0-0
Timestamp: 2025-07-24T05:37:00.907Z
Learning: The DisplayStyleSwitcher component in plugins/woocommerce/client/blocks/assets/js/blocks/product-filters/components/display-style-switcher/index.tsx has been updated so that its onChange prop accepts only a string type (not string | number | undefined), eliminating the need for type assertions when using this component.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
📚 Learning: in wordpress blocks, when there's a styling mismatch between editor and frontend, check if the php r...
Learnt from: gigitux
PR: woocommerce/woocommerce#58902
File: plugins/woocommerce/client/blocks/assets/js/blocks/product-specifications/edit.tsx:205-206
Timestamp: 2025-06-17T12:40:54.118Z
Learning: In WordPress blocks, when there's a styling mismatch between editor and frontend, check if the PHP renderer (like in `ProductSpecifications.php`) adds specific classes to the output. If so, add those same classes to the `useBlockProps` className in the editor component (like in `edit.tsx`) to ensure consistent styling. For example, adding `wp-block-table` class to both frontend and editor ensures core table styles and theme customizations apply consistently.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: woocommerce legacy javascript files in plugins/woocommerce/client/legacy/js/ must use older javascri...
Learnt from: opr
PR: woocommerce/woocommerce#0
File: :0-0
Timestamp: 2025-06-20T17:38:16.565Z
Learning: WooCommerce legacy JavaScript files in plugins/woocommerce/client/legacy/js/ must use older JavaScript syntax and cannot use modern features like optional chaining (?.) due to browser compatibility requirements. Explicit null checking with && operators should be used instead.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: in woocommerce transactional emails, product images have historically had display issues due to lazy...
Learnt from: NeosinneR
PR: woocommerce/woocommerce#0
File: :0-0
Timestamp: 2025-06-26T14:25:08.421Z
Learning: In WooCommerce transactional emails, product images have historically had display issues due to lazy loading attributes being applied, which email clients cannot process since they don't execute JavaScript. This issue existed in both old and new email templates, but became more visible with the new email template system. The fix involves preventing lazy loading on attachment images specifically during email generation by adding skip classes and data attributes.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: in woocommerce blocks, when porting existing code patterns that have known issues (like parseint tru...
Learnt from: samueljseay
PR: woocommerce/woocommerce#58716
File: plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/iapi-frontend.ts:83-101
Timestamp: 2025-06-17T07:07:53.443Z
Learning: In WooCommerce blocks, when porting existing code patterns that have known issues (like parseInt truncating decimal money values), maintain consistency with existing implementation rather than making isolated fixes. The preference is for systematic refactoring approaches (like broader Dinero adoption) over piecemeal changes.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: woocommerce block templates have a predictable structure where each block has one top-level div with...
Learnt from: samueljseay
PR: woocommerce/woocommerce#59142
File: plugins/woocommerce/src/Blocks/BlockTypes/MiniCart.php:594-602
Timestamp: 2025-06-25T06:51:41.381Z
Learning: WooCommerce block templates have a predictable structure where each block has one top-level div with wp-block-woocommerce- class containing arbitrary nested content that should be preserved.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: the core/spacer block in the woocommerce email editor intentionally does not have a dedicated render...
Learnt from: lysyjan
PR: woocommerce/woocommerce#59070
File: packages/php/email-editor/src/Integrations/Core/class-initializer.php:103-141
Timestamp: 2025-06-23T16:55:58.246Z
Learning: The core/spacer block in the WooCommerce email editor intentionally does not have a dedicated renderer class and is handled by the fallback renderer instead of having an explicit render_email_callback assigned in the switch statement.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
📚 Learning: in woocommerce blocks, bold styling for `.wc-block-components-product-details__name` should be scope...
Learnt from: ralucaStan
PR: woocommerce/woocommerce#58782
File: plugins/woocommerce/client/blocks/assets/js/base/components/cart-checkout/product-details/style.scss:21-26
Timestamp: 2025-06-13T15:24:45.923Z
Learning: In WooCommerce blocks, bold styling for `.wc-block-components-product-details__name` should be scoped only to the Cart block (`.wc-block-cart__main`); on the Checkout block, product names are not bold because prices are highlighted instead.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: for woocommerce checkout blocks, lazy loading was removed in favor of direct imports to prevent sequ...
Learnt from: ralucaStan
PR: woocommerce/woocommerce#58782
File: plugins/woocommerce/client/blocks/assets/js/base/utils/render-frontend.tsx:0-0
Timestamp: 2025-06-16T16:12:12.148Z
Learning: For WooCommerce checkout blocks, lazy loading was removed in favor of direct imports to prevent sequential "popping" effects during component loading. This approach prioritizes user experience over code splitting, with minimal bundle size impact and improved performance (1.7s to 1.1s speed score improvement). The checkout flow benefits from having all components load together rather than incrementally.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: for woocommerce mini-cart blocks in plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/, t...
Learnt from: samueljseay
PR: woocommerce/woocommerce#59051
File: plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/mini-cart-contents/inner-blocks/mini-cart-footer-block/index.tsx:66-70
Timestamp: 2025-06-23T05:47:52.696Z
Learning: For WooCommerce mini-cart blocks in plugins/woocommerce/client/blocks/assets/js/blocks/mini-cart/, the standardized conditional pattern for experimental features should be `if ( isExperimentalMiniCartEnabled() ) { blockSettings.save = () => <InnerBlocks.Content />; }` - defaulting to the traditional Save component and only overriding when the experimental feature is enabled.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: in woocommerce's wc_delete_product_transients function, the context check includes both $is_admin_pa...
Learnt from: mreishus
PR: woocommerce/woocommerce#58817
File: plugins/woocommerce/includes/wc-product-functions.php:140-140
Timestamp: 2025-06-13T23:52:46.221Z
Learning: In WooCommerce's wc_delete_product_transients function, the context check includes both $is_admin_page (for regular admin screens) and $is_privileged_ajax (for AJAX requests from users with edit_products capability), ensuring that legitimate admin AJAX operations like product imports/exports can still delete transients.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
📚 Learning: on specific woocommerce admin pages like advanced keys, advanced webhooks, and extensions pages, the...
Learnt from: nerrad
PR: woocommerce/woocommerce#60176
File: plugins/woocommerce/client/legacy/css/admin.scss:9108-9115
Timestamp: 2025-08-04T00:21:08.386Z
Learning: On specific WooCommerce admin pages like Advanced Keys, Advanced Webhooks, and Extensions pages, the screen meta links (#screen-meta-links) are intentionally hidden with display:none because the Help tab and Screen Options functionality is not needed or relevant for these particular routes, making complete DOM removal appropriate rather than just visual hiding.
Applied to files:
plugins/woocommerce/src/Blocks/BlockTemplatesController.php
🔇 Additional comments (3)
plugins/woocommerce/src/Blocks/BlockTemplatesController.php (2)
33-34
: LGTM! Proper integration of legacy script dequeuing.The action hook is correctly added with priority 20, which aligns with the enqueue priority used in legacy blocks, ensuring proper execution order.
36-40
: LGTM! Clean and secure legacy script management.The implementation correctly:
- Uses the safe
is_product()
conditional check- Targets the specific
wc-single-product
script handle- Follows the dequeue-then-selective-enqueue pattern for optimization
This approach allows legacy blocks to re-enqueue scripts as needed while preventing unnecessary loading on block themes.
plugins/woocommerce/src/Blocks/BlockTypes/ProductImageGallery.php (1)
33-46
: LGTM! Proper conditional asset enqueuing.The implementation correctly:
- Calls the parent
enqueue_assets()
method to maintain inheritance- Uses
is_product()
for safe conditional logic- Sets priority 20 to execute after the global dequeue in
BlockTemplatesController
- Follows the established pattern for legacy asset management
@kmanijak Thank you for the review. In the latest commits, I chose to refactor my approach. I believe we should avoid modifying the Because of this significant change, could you review it once more? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I double checked the scenarios and all works fine still. I also checked the other classic templates (I appreciate the is_product()
check!) so they don't load unnecessary dependencies.
I left one minor comment but it's not super crucial so approving again!
if ( is_product() ) { | ||
add_action( 'wp_enqueue_scripts', [ $this, 'enqueue_legacy_assets' ], 20 ); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case, I think we can skip the is_product()
check 🤔 Check makes sense in Classic Template but if Product Image Gallery is used, then we can safely assume the dependencies are needed. WDYT?
Submission Review Guidelines
Changes proposed in this Pull Request
This PR limits loading legacy single product scripts only for legacy blocks.
Script Loading Duplication:
The enqueue logic is intentionally duplicated across
ClassicTemplate.php
andProductImageGallery.php
rather than abstracted into a shared utility to maintain independence between legacy blocks, allowing each to be deprecated separately without creating cross-dependencies.Legacy Script Bundle:
We keep the entire
single-product.js
file rather than splitting it into modules (gallery, zoom, tabs, reviews) to maintain backward compatibility without introducing breaking changes. The file size also makes splitting not worth the effort.How to test the changes in this Pull Request
Using the WooCommerce Testing Instructions Guide, include your detailed testing instructions:
single-product.js
and its dependencies loaded.single-product.js
and its dependencies loaded.single-product.js
and its dependencies loaded.single-product.js
loaded on the frontend without gallery dependencies.single-product.js
and its gallery dependencies aren't loaded on the frontend.Changelog entry
Changelog Entry Details
Significance
Type
Message
Limit loading legacy single product scripts only for legacy blocks