people are viewing this right now
${function() {
const variantData = data.variant || {"id":"4e23f786-e964-471e-ad6c-bc3407d38b9e","product_id":"2608d96a-ecb3-4a98-a64f-c4751e621082","title":"","weight_unit":"kg","inventory_quantity":1000,"sku":"sku1677824891660","barcode":"","position":1,"option1":"","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":43.89,"min_quantity":1}],"weight":"0","compare_at_price":"56.89","price":"43.89","retail_price":"56.89","available":true,"url":"\/products\/big-snake-necklaces?variant=4e23f786-e964-471e-ad6c-bc3407d38b9e","available_quantity":999999999,"options":[],"off_ratio":23,"flashsale_info":[],"sales":0};
const saveType = "amount";
const saveText = "Save {{saved_amount}}";
const productLabelDiscountOn = true;
return `
-
${saveText.replace('\{\{saved_amount\}\}',
saveType == 'percentage'
? variantData.off_ratio + '%'
: ``
)}
`;
}()}
${function() {
const minInventory = parseInt('10');
const maxInventory = parseInt('50');
const randomInventory = Math.round(Math.random() * (maxInventory - minInventory)) + minInventory;
const customText = "Only {stock} item(s) left in stock!".replace(/\{stock\}/g, '' + randomInventory + '');
const barWidth = (randomInventory / maxInventory) * 100 + '%';
return `
`;
}()}
Product was out of stock.
Product is unavailable.
${function(){
const variantData = data.variant || {"id":"4e23f786-e964-471e-ad6c-bc3407d38b9e","product_id":"2608d96a-ecb3-4a98-a64f-c4751e621082","title":"","weight_unit":"kg","inventory_quantity":1000,"sku":"sku1677824891660","barcode":"","position":1,"option1":"","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":43.89,"min_quantity":1}],"weight":"0","compare_at_price":"56.89","price":"43.89","retail_price":"56.89","available":true,"url":"\/products\/big-snake-necklaces?variant=4e23f786-e964-471e-ad6c-bc3407d38b9e","available_quantity":999999999,"options":[],"off_ratio":23,"flashsale_info":[],"sales":0};
return `
`
}()}