1
votes

I offer free delivery on orders over £75 in my store, so I'd like to show an additional <div> element on each product page where the product price is 75 or greater.

I had assumed I could use conditional handlebar commands like this:

{{#if price.with_tax.raw >= 75}}
    <div>Qualifies for free delivery</div>
{{/if}}

But this just gives me a 500 error.

Is this sort of conditional logic even possible, and if so, what is the correct syntax? Is price.with_tax.raw the right stencil object to use?

1

1 Answers

2
votes

Try this:

{{#if price.with_tax.value '>=' 1}}
    show something
{{/if}}