Skip to content

Commit 7f4e5f6

Browse files
committed
refactor(readme): add instance methods for datepicker readme
1 parent 8e589d3 commit 7f4e5f6

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,11 @@ You can check [index.js](https://github.com/xgfe/react-native-datepicker/blob/ma
6161
| customStyles | - | `number` | The hook of customize datepicker style, same as the native style. `dateTouchBody`, `dateInput`...|
6262
| showIcon | true | `boolean` | Controller whether or not show the icon |
6363
| placeholder | '' | `string` | The placeholder show when this.props.date is falsy |
64+
| onDateChange | - | `function` | This is called when the user confirm the picked date or time in the UI. The first and only argument is a date or time string representing the new date and time formatted by [moment.js](http://momentjs.com/) with the given format property. |
6465

65-
## Methods
66-
66+
## Instance Methods
6767

6868
| Method | Params | Description |
6969
| :------------ |:---------------:| :---------------:|
70-
| onDateChange | dateStr:string, date:date | This is called when the user confirm the picked date or time in the UI. The first and only argument is a date or time string representing the new date and time formatted by [moment.js](http://momentjs.com/) with the given format property. |
70+
| onPressDate | - | Manually open the date picker panel |
71+
| onPressCancel | - | Manually close the date picker panel like, similarly pressing cancel btn |

0 commit comments

Comments
 (0)