Skip to content

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

@parveen-bhatia

Description

@parveen-bhatia

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions