New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

rn-react-native-calendar

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rn-react-native-calendar

calendar package for react native

  • 5.1.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

rn-react-native-calendar

This is a calendar package for react native

Installation

npm install rn-react-native-calendar

Note

Week Calendar Usage

import {WeekCalendar} from "rn-react-native-calendar"


const App =()=>{
    const items = {
        '2022-04-28':{},
        '2022-05-03':{}
    }
    return(
        <View>
            <WeekCalendar items={items} itemsOnThisDate={(items)=>console.log(items)} />
        </View>
    )
}






Screenshot_20220503_185314 (1)

Week Calendar Props

Propdescriptiontypedefualt value
itemsitems which you want to be marked on calendarobject{}
buttonColorcolor on left and right button backgroundstring'#FFEADF'
selectedDateColorselected date background Colorstring'#ff5a3d'
todayDateColortoday's date backgroundColorstring'gray'
itemsOnThisDatecallback which triggers when you click on date with items datafunction(item)=>{ }

CalendarModal Usage

import {CalendarModal} from "rn-react-native-calendar"

const App =()=>{
    const [showCalendar,setShowCalendar] = useState(false)
     const [date,setDate] = useState(new Date())
    const items = {
        '2022-04-28':{},
        '2022-05-03':{}
    }
    const onDayPressChanges = (date)=>{
    
    return(
        <View>
            <CalendarModal 
            items={items}
             currentDate={date} 
            visible={showCalendar} 
            onDayPress={(date)=>onDayPressChanges(date)} 
            onDismiss={()=>setShowCalendar(false)} 
            selectedDateColor={'#ff5a3d'}
            
            />
        </View>
    )
}

CalendarModal Props

Propdescriptiontypedefualt value
itemsitems which you want to be marked on calendarobject{}
visibleshould show calendar modal or notbooleanfalse
selectedDateColorselected date background Colorstring'#ff5a3d'
onDayPresscallback triggered when a day is pressedfunction(data)=>{ }
onDismisscallback which triggers when calendar modal closesfunction()=>{ }

Screenshot_20220503_182451_com example (1) Screenshot_20220503_182454_com example Screenshot_20220503_182459_com example

Contributing

feel free to contribute

License

MIT

Keywords

FAQs

Package last updated on 03 May 2022

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc