Looking to create a unique attribute variation feature for an e-commerce website based on user-selected attribute values.
I'm facing an issue in accessing the attribute values from the v-model and determining the appropriate data type for the v-model. Any guidance or suggestions would be greatly appreciated!
Here is the snippet of code I've been working on:
Thank you in advance!
<div v-for="(attribute, index) in attributes">
<p>{{ attribute.name }}</p>
<div v-for="(attributevalue,indexval) in attribute.attribute_values">
<input v-model="attributes[index][indexval]" :value="attributevalue.id">
<label>{{ attributevalue.name }}</label>
</div>
</div>
<p>Generate</p>
export default {
props:{
attributes:{
type:Array
}
}
}