Product Single
Product Single Component Documentation
Overview
Model Documentation
model
prop that should be an object containing details about the product. This object typically includes:id
: Unique identifier for the product.cssClass
: CSS classes to apply to the product section.additionalFields
: Optional fields for additional information.Model Structure
model
object structure is as follows:{
"id": "string",
"cssClass": "string",
"additionalFields": [
{
"fieldName": "string",
"label": "string",
"authenticated": "boolean"
}
],
}
Example Model
model
object:{
"id": "12345",
"cssClass": "product-highlight",
"additionalFields": [
{
"fieldName": "brand",
"label": "Brand",
"authenticated": false
},
{
"fieldName": "category",
"label": "Category",
"authenticated": false
}
],
}
Component Structure
1.
2.
3.
4.
5.
HTML Template
Functionality
Methods
Localization
{{this.$t('product-add-to-cart')}}
{{this.$t('product-add-to-list')}}
Notes
model
data before rendering to avoid errors.