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

165
Vistas
Select box not resetting - React JS

This might be pretty basic but i am not able to find out what is wrong here. I have a react form in which i am using a custom select box to list the students. I want to clear the selection when isChecked is set to false.

 let studentId = watch("std.id"); // is of type number
      
<Select
 name="std.id"
 placeholder="Select Students"
 registerResult={register("std.id")}
 list={studentList}
 disabled={!isChecked}
/> 

I tried emptying with "" the value also tried assigning it to null like below, but didnt work. can anyone tell me why is it not resetting?

if(!isChecked){
  studentId = null;  //Select box still shows the selected value even after this
}

        
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