Skip to main content

Calendar.Day

Import

import { Calendar } from "@dhua5922/react-native-kit";

Basic Example

Live Editor
function Example() {
  const [date, setDate] = useState(new Date());

  return (
    <Calendar.Day
      value={date}
      onPress={(date) => setDate(date)}
      key={date}
      textStyle={{ color: "#ffffff" }}
    >
      {date.getDate()}
    </Calendar.Day>
  );
}
Result
Loading...

Props

note

Include all props from Pressable

NameTypeDefaultDescription
valueDateDate of day.
onPress(date: Date) => voidCallback fired when selecting day.
textStyleobject or any[]text style for day.