<option v-for="profile in profiles" :value="profile.brand.name">
{{ profile.brand.name }}
</option>
BrandName
BrandName2
BrandName2
BrandName3
methods: {
uniqueFilter: function(profile) {
if(profile.brand.name === profile.brand.name) {
как прописать?
}
}
}
BrandName
BrandName2
BrandName3
computed: {
brands() {
return [...new Set(this.profiles.map(n => n.brand.name))];
},
},
<option v-for="brand in brands" :value="brand">{{ brand }}</option>