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

268
Vistas
How can I trigger when a specific button is pressed in react-native-picker-select?

I am using react-native-picker-select. When there is data called ingre, I want ingrebool to be false when a,b,c,d is pressed and to be true when e is pressed. What should I do?

this is my code

            export const ingre = [
                { label: 'a', value: 'Tangerinefeed' },
                { label: 'b', value: 'dryexamfeed' },
                { label: 'c', value: 'wetfeed' },
                { label: 'd', value: 'sawdust' },
                { label: 'e', value: 'etc' },
            ];



            
            export const ArrowIconPickerObj = ({ingre }) => {
            const [ingrebool, setIngrebool] = useState(false)
                return (
                    <RNPickerSelect
                        items={ingre}
                    />
                )

            }
about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You figured it out yourself already: Set ingrebool to be false when a,b,c,d is pressed and to be true when e is pressed.

 <RNPickerSelect
   items={ingre}
   onValueChange={value => setIngrebool(value === "etc")}
 />
about 4 years ago · Juan Pablo Isaza Denunciar
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