Today I met such a need: When you enter a name, you can select one of the dropdown options if it is available. If not, you can enter it yourself. The El-Select component in Element UI has a default-first-option property that is selected with the Filterable carriage return event. But it doesn’t satisfy the need, the need is to write the data out of focus
At this point, I added an out-of-focus event @blur=”selectBlur($event)”
selectBlur(e) {
if (e.target.value) {
this.$set(this.owner, 'name', e.target.value); }}Copy the code
Perfect for input fields