var categoryList = "[Service,Ticket,Bill,Entertainment,Restaurant]"
.slice(1, -1) // get `[` and `]`removed string
.split(','); // split based on comma to get array
console.log(
categoryList
)
var yourString = "[Service,Ticket,Bill,Entertainment,Restaurant]"
var categoryList = yourString.substring(1, yourString.length-1).split(",") // removing [] and splitting with `,`
categoryList.substring(1, categoryList.length - 1).split(',')