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

145
Vistas
Input re-rendering and losing focus every time I type when using Formik

When using FieldArray in Formik my inputs are always rerendered and thus they lose focus when a user types.

   <FieldArray
      name="wallets"
      className="space-y-4"
      component={(arrayHelpers) => (
        <>
          {
            formik.values.wallets.map((wallet, i) => (
              <div
                key={i}
   {...}

Following the docs, Formik uses an index as the child key, which is not a good practice, but I don't have any other immutable value in the wallet to use (all of them might be changed within form). I believe the re-render is not a matter of using the index as a key but simply Formik re-rendering the whole mapped values each time a value changes.

Is there any way to prevent this to happen without being a huge hack?

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