Socket
Book a DemoInstallSign in
Socket

react-native-slideable-calendar

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-slideable-calendar

calendar

2.0.16
latest
Source
npmnpm
Version published
Weekly downloads
28
1300%
Maintainers
1
Weekly downloads
 
Created
Source

react-native-slideable-calendar-strip Build Status npm juejin license

Live Calendar Demo.mp4

Feature

  • Support pull down gesture
  • Support go today
  • Support support marked date
  • Support Chinese lunar
  • Support current week of this year (W21)
  • Support both Date and Date string ('2018-01-01') types
  • Support customized start of week

How to use

Install package:

npm install --save react-native-slideable-calendar-strip
# or
yarn add react-native-slideable-calendar-strip

Import to your app:

import CalendarStrip from 'react-native-slideable-calendar-strip';

Use the component:

<CalendarStrip
  isChinese
  showWeekNumber
  showChineseLunar
  selectedDate={this.state.selectedDate}
  onPressDate={(date) => {
    this.setState({ selectedDate: date });
  }}
  onPressGoToday={(today) => {
    this.setState({ selectedDate: today });
  }}
  onSwipeDown={() => {
    alert('onSwipeDown');
  }}
  markedDate={['2018-05-04', '2018-05-15', '2018-06-04', '2018-05-01']}
  weekStartsOn={1} // 0,1,2,3,4,5,6 for S M T W T F S, defaults to 0
/>

API

API nameDesc
selectedDateThe current selected date, Required.
onPressDatePress date callback, Optional, (date) => {}
onPressGoTodayPress gotoday button callback, Optional, (today) => {}
markedDateMarked highlighted date array, Optional, ['2018-01-01', '2018-02-01']
onSwipeDownSwipe down gesture callback, Optional, () => {}
isChineseShow Chinese Week or not, default false,
showChineseLunarShow Chinese Lunar or not, default false,
showWeekNumberShow week number or not, default false,
weekStartsOnSet start of week, Optional, defaults to 0, 0 1 2 3 4 5 6 for S M T W T F S

Keywords

calendar

FAQs

Package last updated on 25 Mar 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.