useDate

A custom hook that returns a function for using a modal with a DatePicker component. The returned function can be used to display the modal and retrieve the selected date.

  • Returns () => { then: (onData: Fn) => void; toPromise: () => Promise<any> }

    A function that can be called to display the modal and retrieve the selected date.