iOS "onChange" is not getting invoked with react native new architecture enabled

Abierto
#995 8 comentarios 6 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
52/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Tranquilo
Stack tecnológico
ios, javascript, react-native
Área
mobile

Línea de trabajo

Start by reading the target-action setup in ios/RNDateTimePicker.m around lines 29–31, then trace how the picker handles changes with React Native 0.79.2’s new architecture enabled. Reproduce the issue using the provided spinner example on iOS 18.x; done means onChange fires when the date or time changes with the new architecture enabled.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Summary

(iOS) On change of date and time, onChange is not getting invoked when using with react native version 0.79.2 where react native new architecture is enabled.

Reproducible sample code

  onDateTimeChange = (_, dateTime) => {
    // Not getting invoked
  };
      <RNDateTimePicker
        display="spinner"
        value={selectedDateTime}
        minimumDate={MIN_DATE}
        maximumDate={MAX_DATE}
        mode={'datetime'}
        onChange={this.onDateTimeChange}
        timeZoneOffsetInMinutes={timezoneOffset}
      />

Steps to reproduce

  1. Integrate this library with RN version 0.79.2
  2. Open the Date time picker and change the date by spinning

Describe what you expected to happen:

  1. onDateTimeChange should be invoked

Environment info

datetimepicker version: 8.4.3
iOS version: 18.x
React Native version: 0.79.2

Problem: After some investigation found that this is because target action has been enabled only when react native new architecture is disabled.

Lenguaje dominante
JavaScript
Estrellas
2.9k
Forks
459
Merge medio
4 d 16 h
PR fusionados (30 d)
5

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de react-native-datetimepicker/datetimepicker

Todos los issues de react-native-datetimepicker/datetimepicker

Issues similares

Más issues de JavaScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.