DateTimePicker - Typescript


I’d like the DateTimePicker to show up on load.
I’m using React Typescript.

Hi @Ilan_Levy,

Welcome to the Mobiscroll Forum! If you are using a functional approach in your code base, here’s an example on how to show the Datetime component on load:

import { Datetime, Input } from '@mobiscroll/react';

export function MyPage() {
    const myRef = React.useRef<any>(null);
    React.useEffect(() => {
        if (myRef.current) {
    return (<Datetime ref={myRef}>
        <Input />

By the way, this is also applicable to any other Mobiscroll component, not only the Date & Time.
Let me know if you find this helpful!