Search code examples
fullcalendarrecurringgcal

How does FullCalendar interpret recurring events from a Google Calendar?


I'm using a custom back-end to store event information. Recurring event data are stored in iCal format in the database. Retrieving this and building a valid recurrence rule is easy. Interpreting those rules is obviously not as easy.

The front-end is the jQuery calendar, FullCalendar. When supplying FullCalendar with a valid events feed from Google Calendar, recurring events are displayed 100% accurately for me. This confuses me because there is no code in the gcal.js file that sends the gd$recurrence data to FullCalendar.

gcal.js takes 8 fields from the Google output, places them into an event which is pushed into an events stack. None of those 8 fields has anything to do with recurrence.

The JSON Event object that FullCalendar uses does not have a 'recurrence' property, so I can not simply throw my recurrence rules into event.recurrence and have it work.

I've tried simulating Google's output and tricking FullCalendar into thinking it's a legitimate feed, but that didn't work either.

So, my question is, how does FullCalendar interpret these recurring events accurately? And of course, how can I get my iCal recurrence data to work the same way?


Solution

  • I discovered that I was missing the "singleevents" parameter in my API calls to Google. FullCalendar does not interpret the RRULE. Google does.