0👍
I also tried to achieve this with default approach but it was not working for me as well. You can achieve this by a workaround for now.
In onMounted()
lifecycle hook, Manipulate the input array and add a new property in each object which will contain the concatenated value.
data () {
return {
items: [
{ state: 'Florida', abbr: 'FL' },
{ state: 'Georgia', abbr: 'GA' },
{ state: 'Nebraska', abbr: 'NE' },
{ state: 'California', abbr: 'CA' },
{ state: 'New York', abbr: 'NY' },
],
}
}
onMounted() {
this.items = this.items.map(obj => obj.title = obj.state + ' - ' + obj.abbr)
}
In HTML Template :
item-title="title"
Source:stackexchange.com