2
I’m developing an app with React Turn on and I wanted the calendar to show only the month and the year. I’m trying with the dependency React-Native-calendars but was unsuccessful.
import React, { Component } from 'react'
import { View, StyleSheet } from 'react-native'
import { Calendar } from 'react-native-calendars'
class ReleasesScreen extends Component {
render() {
return (
<View style={styles.container}>
<Calendar
hideExtraDays={true}
hideDayNames={true}
theme={{
calendarBackground: '#2195F2',
arrowColor: '#fff',
monthTextColor: '#fff'
}}
/>
</View>
)
}
}
My app looks exactly like this: https://i.stack.Imgur.com/Qhfk0.png
and wanted to leave that way without the days Component: https://i.stack.Imgur.com/Ohsdv.png
If anyone can give me a solution or other dependency I do it. Thank you!
would also like to know
– Raphael Prado de Oliveira
Looking at the documentation, I didn’t see that the component has the option to use only months. Better you look for a component that gives you the option
– João Vertelo
Have you tried this Library? I think you’d better try other libraries https://github.com/react-native-community/datetimepicker
– Stênio Barroso de Moraes