Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Caching issue adding items to cart with All Products block #6390

@bradhogan

Description

@bradhogan

Describe the bug

When adding items to the cart (it seems to happen mostly when doing so from the main shop page), the item does not appear in the cart until you do a hard refresh. When using the default WP theme, WooCommerce Blocks and Gutenberg, the issue is there. If WooCommerce Block is deactivated, the issue does not occur.

To reproduce

  1. Go to WooCommerce > Settings > Products > check both 'add to cart' behaviors to redirect and use AJAX, then save
  2. On your main shop page, add the All Products block
  3. View shop page in front-end and click "add to cart" for any product
  4. Should be redirected to the cart page but the product is not there
  5. Make sure to try in multiple browsers with no items in the cart and a clear cache

Expected behavior

Item should immediately appear in the cart

Environment

WordPress (please complete the following information):

  • Core version: 5.9.3
  • Gutenberg version (if installed): 13.1.0
  • WooCommerce version: 6.4.1
  • WooCommerce Blocks version: 7.5.0
  • Site language: English
  • Any other plugins installed: no

Desktop (please complete the following information):

  • OS: mac
  • Browser: chrome, safari and ff

Metadata

Metadata

Assignees

Labels

block: all productsIssues related to the all products block.priority: highThe issue/PR is high priority—it affects lots of customers substantially, but not critically.type: bugThe issue/PR concerns a confirmed bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions