[Web] Remove redundant event detail properties#431
Conversation
Assisted-By: devx/7de6cdaa-3194-43df-b108-d324ae4d378d
Package Size
Web file breakdown
Measured from the PR base SHA and PR head SHA. The file breakdown shows uncompressed sizes within each package artifact, so individual files do not sum to the compressed artifact total. This comment reports package artifact sizes only; it is not a final app binary-size report. |
|
Do we need to update the readme? |
Do you mean to add a migration note? Only web alpha consumers would be affected right? I think we should just add a note in the release of the next version. |
|
This is the part I was thinking of https://github.com/Shopify/checkout-kit/blob/main/platforms/web/README.md#checkout-lifecycle
|
Good catch! I'll update it right now. |
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Merge activity
|
### tl;dr - Updated lifecycle payload tables and examples to access event data through `event.detail.checkout`. - Corrected checkout model field casing and clarified how event data is mirrored to the element. ### Why This PR keeps the Web package README aligned with the event detail API introduced in #431. The README ships with the npm package, so consumers of the next v4 release get examples that match the runtime behavior and TypeScript types.


tl;dr
order,lineItems,totals, andmessagesaliases from Web checkout event details.checkoutsnapshot.Why
The aliases duplicated protocol-backed checkout fields and created two apparent sources of truth. A single checkout payload keeps the public event API smaller and prevents aliases from drifting from the decoded protocol model.