The issue: when we make a wrapper for el-input, the autocomplete-suggestions component gets incorrect $refs, which can be avoided by using a getInput() method.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Existing Component
Yes
Component Name
Autocomplete
Description
Get
<input>
in autocomplete-suggestions usinggetInput()
methodAutocomplete-suggestions.vue component contains a reference, which allows to get input value from parent component.
But the component
el-input
already has agetInput()
method, why we can't just use it instead of$refs
?The issue: when we make a wrapper for
el-input
, theautocomplete-suggestions
component gets incorrect$refs
, which can be avoided by using agetInput()
method.Exemple: https://gist.github.com/martdn/1da5addd6a0f55c235c97d4c4e7053bd
Steps to reproduce
el-input
in a component, e.g.v-input
autocomplete
and changeel-input
stock component tov-input
custom component in the template https://gist.github.com/martdn/1da5addd6a0f55c235c97d4c4e7053bd#file-autocomplete-vueautocomplete-suggestions
addresses thev-input
component by$refs
and throws an error