1.1.6 • Published 4 years ago

react-native-material-calendar v1.1.6

Weekly downloads
6
License
ISC
Repository
github
Last release
4 years ago

react-native-material-calendar

Getting started

$ npm install react-native-material-calendar --save

Demonstration

So smooth, such cool, very fast, wow

Mostly automatic installation

$ react-native link react-native-material-calendar

Manual installation

Android

  1. Open up android/app/src/main/java/[...]/MainApplication.java
  • Add import com.sevenswen.materialcalendar.RNMaterialCalendarPackage; to the imports at the top of the file
  • Add new RNMaterialCalendarPackage() to the list returned by the getPackages() method
  1. Append the following lines to android/settings.gradle:
    include ':react-native-material-calendar'
    project(':react-native-material-calendar').projectDir = new File(rootProject.projectDir, 	'../node_modules/react-native-material-calendar/android')
  2. Insert the following lines inside the dependencies block in android/app/build.gradle:
      compile project(':react-native-material-calendar')

Usage

import RNMaterialCalendar from 'react-native-material-calendar';

...
<RNMaterialCalendar
              ref={calendar => this.calendar = calendar}
              width={400}
              showDate="all"
              selectionMode="single"
              initDecorator={true}
              eventsDates={this.state.eventsDates}
              weekDayFormatter={["S","M","T","W","T","F","S"]}
              topbarVisible={false}
              onDateChange={(event) => {
                this.setState({selectedDate: new Date(event.date)})}
              }
              onMonthChange={(event) => {
                this.setState({currentMonth: new Date(event.date)})}
              }
          />
...
1.1.6

4 years ago

1.1.5

10 years ago

1.1.4

10 years ago

1.1.3

10 years ago

1.1.1

10 years ago

1.1.0

10 years ago

1.0.5

10 years ago

1.0.4

10 years ago

1.0.3

10 years ago

1.0.2

10 years ago

1.0.1

10 years ago

1.0.0

10 years ago