Vuejs - Mendapatkan elemen terakhir dari array string split
const str = "hello,how,are,you,today?"
const pieces = str.split(/[\s,]+/)
const last = pieces[pieces.length - 1]
console.log({last})
Run code snippet
Angry Albatross