I'm using the JT Apple calendar pod to display the calendar what i would like to do is to put two buttons ( previous and next to scroll fast than swiping left or right ) but i can't find a way to get the index path for the collection view
> func configureCalendar(_ calendar: JTAppleCalendarView) ->
> ConfigurationParameters
> {
> formatter.dateFormat = "yyyy MM dd"
> formatter.timeZone = Calendar.current.timeZone
> formatter.locale = Calendar.current.locale
> let startDate = Date() //today
> let endDate = Calendar.current.date(byAdding: .month, value:2, to: startDate) let parameters = ConfigurationParameters(startDate:
> startDate, endDate: endDate!)
> return parameters
> }
I need to implement the nextButtonPressed to swipe right and the Previous Button but without passing the corresponding dates
You do not have to find the index path for the collectionView.
just call these functions,
calendarView.scrollToSegment(.next) // Scrolls to next
calendarView.scrollToSegment(.previous) // Scrolls to previous
calendarView.scrollToSegment(.start) // Scrolls to start of calendar
calendarView.scrollToSegment(.end) // Scrolls to end of calendar