4👍
✅
Well, for those who’ll have the same issue, this is were my problem was, it should be .then(function(response) {
instead of .then((response) => {
fetchStates: function () {
this.$http.get('/api/locations/all_states').then(function(response) {
states = $.parseJSON(response.responseText).states
paymentInfo.$set('states', states)
}).then(function() {
$('.cs-select').trigger('chosen:updated')
})
},
Source:stackexchange.com