I'm working on rewriting the if statements for my collection page on shopify. I'm trying to get the item-price line to show the text 'out of stock' when the product is unavailable/when all variants are sold out. I can get the code working if it's under 3 conditions, but not sure how to add an additional condition.
the 4 conditions are:
if the product is on sale, show the price comparison
if the product price varies, show the lowest price
if the product and all variants sold out, show out of stock text
else, show normal pricing
I've tried a few different ways, below are what I'm stuck on...Any help is appreciated!
img1