File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
sample-apps/update-line-item/extensions/update-line-item-js/src Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 1
1
// @ts -check
2
2
3
3
/*
4
- A straightforward example of a function that expands a bundle into its component parts.
5
- The parts of a bundle are stored in a metafield on the product parent value with a specific format,
6
- specifying each part's quantity and variant.
4
+ A straightforward example of a function that updates a line item title and price based on attributes.
7
5
8
- The function reads the cart. Any item containing the metafield that specifies the bundle parts
9
- will return an Expand operation containing the parts.
6
+ The function reads the cart. Any item with a specific line item attribute will be used
7
+ to generate an update operation with a custom title, and price based on simple math using
8
+ the line item attribute value.
10
9
*/
11
10
12
11
/**
You can’t perform that action at this time.
0 commit comments