Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change minute increment on react-native-modal-datetime-picker

I am using react-native-modal-datetime-picker for a time picker. I want to change the minute interval to be 15 minutes instead of 1 minute. Is this possible? Thanks!


1 Answers

Following the docs, there is a property called minuteInterval which gets a number (defaults as 1) and can change the interval of the minutes input.

Use it like this:

render() {
    return (
      <>
        <DateTimePicker
          minuteInterval={15}
        />
      </>
    );
  }
like image 107
SomoKRoceS Avatar answered Sep 07 '25 17:09

SomoKRoceS



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!