[JavaScript]useAppMetafields
let j,productId; const cartLines = useCartLines(); const appMetafields = useAppMetafields(); if(appMetafields.length){ cartLines.forEach((cartLine,i)=>{ productId = cartLine.merchandise.product.id.split("/").pop(); for(j=0;j<appMetafields.length;j++){ if(appMetafields[j].target.id === productId){ if(appMetafields[j].metafield.key === "metafieldKey" && appMetafields[j].metafield.value === "metafieldValue"){ //処理 } break; } } }); }