The question is about popular calendar library: https://github.com/WenchaoD/FSCalendar
How can I set the correct number of dots, displaying the number of events for a given day in fs calendar?
Now if I try this simple code:
func calendar(_ calendar: FSCalendar, numberOfEventsFor date: Date) -> Int {
let dateString = self.dateFormatter2.string(from: date)
if self.datesWithFourEvents.contains(dateString) {
return 4
}
if self.datesWithFiveEvents.contains(dateString) {
return 7
}
return 0
}
The calendar will show maximum 3 dots per day.
How can this be fixed? If we need e.x. to show 4 or 7 dots - what should I change in code?