vue-tel-input
vue-tel-input copied to clipboard
Is there any reasons cause this problem?
i try many times,but it still show undefined. i don't konw how to solve it
i try many times,but it still show undefined. i don't konw how to solve it
Use event listener @open and replace the arrow yourself.
happen with me too
hello. I use a bit older version "vue-tel-input": "5.3.0" and it works fine without this redundant string
I don't understand why this is closed. I finally found a way :
If you don't care about the arrows and just want to make 'undefined' disappears you only have to add a template with an empty span to the tel-input component:
<vue-tel-input> <template v-slot:arrow-icon> <span></span> </template> </vue-tel-input>
If you want the arrows you can do like this:
Add a data in your parent component
open: false
then add a template v-slot in the tel-input component and listen for the open and close event:
<vue-tel-input @open="open = true" @close="open = false" > <template v-slot:arrow-icon> <span v-if="open">▲</span> <span v-else>▼</span> </template> </vue-tel-input>
After some digging I tracked down the issue to this commit and the vue-template-compiler upgrade.
Upgrading to latest vue version fixed the issue.
So, if you're using vue < 2.6.13
, either upgrade to [email protected]
or use vue-tel-input <= 5.3.0
.
@iamstevendao would it be possible to add this requirement to package.json's peerDependencies
?