Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

94
Vistas
How to apply vuelidate and a value to the input field in Vue

I am using vuelidate in my form to validate my input field. But at the same time, I am getting the user object as a prop and I want to show the first name of the object as a value of input field. Here is the code that I try but since I trim the value of the input field, I think I am not able to use v-model to show my value anymore.

<input type="text" id="first_name" class="form-control" v-model="user.attributes.first_name"
                   @keyup.enter="updateProfile" v-model.trim="$v.first_name.$model"
                   :class="{'is-invalid':$v.first_name.$error, 'is-valid':!$v.first_name.$invalid}">
about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda