godbasin / vue-select2

select2 component in vue.
MIT License
123 stars 62 forks source link

@change not working #65

Open EugenGedroyc opened 2 years ago

EugenGedroyc commented 2 years ago

I checked it in this repository @change="myChangeEvent($event)"

I need to filter options('sorter' in settings work fine) but i can't to get modelValue from 'input' that i type any symbols in. How can i get the first symbols that i typed ? Work only event @select but it is not suitable for this task

<Select2
  value="modelValue"
  @input="(e) => modelValue = e.target.value" //or @change
  :settings="sorter: function (results) {
    return results.filter((item) => item.text.startsWith(modelValue))
  }"
/>