v-text-field formatting numbers with thousands separators #17871
Unanswered
MrGonzo1024
asked this question in
Q&A
Replies: 3 comments 8 replies
-
You could get help from some text mask library e.g. https://github.com/beholdr/maska |
Beta Was this translation helpful? Give feedback.
7 replies
-
I've used https://www.npmjs.com/package/vue-imask |
Beta Was this translation helpful? Give feedback.
1 reply
-
this works great, and easy to setup |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I apologize if this was asked before, but I searched and couldn't find the answer. I am using Nuxt 3 with Vuetify 3, and I would like to use the v-text-field to capture numbers but display the numbers formatted when the user tabs away from the field. For example, if the user entered 10000000, then have it display 10,000,000 when the user tabs away. I would still need the v-text-field to capture the numeric value though. I have it bound to a variable with v-model so I can't just change the value to a text formatted representation with the field loses focus.
Also, I looked for some solutions online, and found a couple but they are not compatible with Vuetify 3.
Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions