Conversation
…7.14.x peer requirement
Move the 3 loose root-level spec markdown files (lift-useOptimisticCart design + 592-line plan, and the split-Await design) into a convention- compliant 2026-04-10--optimistic-cart-fix-attempts/ folder. Add a README marking them deprecated and explaining both approaches were abandoned in favor of the shipped zustand sync.
Documents what actually shipped: the custom useCart() zustand sync that replaced Hydrogen's useOptimisticCart. Includes README, plan.md with the store.ts architecture, and a work-logs.md timeline from the two abandoned attempts to the merged solution.
The lift approach was never implemented. Set status to deprecated, add a Resolution section noting it was abandoned, and cross-link to the shipped zustand spec and the attempts archive.
The remove CartForm used an anonymous fetcher whose only sync point (ItemRemoveButtonInner) unmounts the moment the line is optimistically spliced out, so the authoritative post-remove cart (with correct cost) was discarded by React Router. The store.ts fallbacks recompute totalQuantity but never cost, leaving the checkout total frozen until a later add/quantity change. Give the remove form a stable fetcherKey and read it from the always- mounted CartSummary via useFetcher + useCartFetcherSync (the same pattern already used for discount-code/gift-card removal), and include it in isCartUpdating so the total skeletons during the transition. Server- computed cost is now used; no store.ts change needed. Fixes both the drawer and the cart page.
Add a post-merge follow-up section to plan.md, a work-logs entry, and a README note for the stale-checkout-total fix. Notes that the tombstone / useCart() design was unchanged — the gap was a missing keyed fetcher.
react-player v2's CommonJS "react-player/lazy" build broke under Vite 8's
dependency optimizer: the dynamic import resolved to a {__esModule, default}
wrapper object, so React.lazy threw "Element type is invalid".
v3 is ESM-only with a clean forwardRef default export and lazy-loads its
player backends internally, removing the interop layer entirely. Switched
the import to bare "react-player" and renamed the "url" prop to "src"
per the v3 API.
Add rounded-md/overflow-hidden to video, 3D model, and external video containers in both the inline product gallery and the zoom modal. Also tidy the zoom thumbnail scroll height to max-h-175 and give non-image zoom media a full-height container.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What's in this release
New features
Bug fixes
Improvements
Other