1.0.8 • Published 1 month ago

rn-calendar-simple v1.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
1 month ago

react-native-calendar

Test Lint

Installation

yarn add rn-calendar-simple
npm install rn-calendar-simple

How use

import { useState } from 'react';
import { Text, View } from 'react-native';
import { Calendar } from 'rn-calendar-simple';

export default function App() {
  const [selectedDate, setSelectedDate] = useState<Date>(new Date());
  return (
    <View>
      <Text>{selectedDate.toLocaleString()}</Text>
      <Calendar value={selectedDate} onChange={setSelectedDate} />
    </View>
  );
}

Props

PropTypeDescription
value (optional)DateThe calendar value.
onChange (optional)(d: Date) => voidThe method called when an update is performed.
min (optional)DateThe minimum date to be selected.
max (optional)DateThe maximum date to be selected.
monthLabel (optional)ArrayThe name of the months.
weekLabel (optional)ArrayThe name of the weeks.
1.0.8

1 month ago

1.0.7

1 month ago

1.0.2

8 months ago

1.0.1

9 months ago

1.0.0

9 months ago