Intro-to-Vue-3 icon indicating copy to clipboard operation
Intro-to-Vue-3 copied to clipboard

L4-end is missing the usage of inventory and onSale data properties.

Open gastonquiroga opened this issue 3 years ago • 1 comments

During lesson 4 an inventory property is added and used on the html to show if the product has stock. The challenge asks to add an onSale boolean property to show an "On Sale!" message. On L4-end branch, both properties are inside the data element but they're not being used inside the html.

gastonquiroga avatar May 23 '21 23:05 gastonquiroga

The solution on CodePen looks correct.

index.html in L4-end branch need to write following codes. (Quoted solution index.html on CodePen)

~ abbrev. ~
            <p v-if="inventory > 10">In Stock</p>
            <p v-else-if="inventory <= 10 && inventory > 0">Almost sold out!</p>
            <p v-else>Out of Stock</p>
            <!-- solution -->
            <p v-if="onSale">On Sale!</p>
            <!-- solution -->
~ abbrev. ~

P.S. I missed the PR #54

tis-h-sato avatar Jun 02 '21 02:06 tis-h-sato