I’m attempting to integrate Google Calendar events into my React application using FullCalendar, but despite following the documentation closely and setting my calendar to public, I haven’t been able to successfully retrieve events. Here’s the relevant code snippet:
` <FullCalendar
ref={calendarRef}
plugins={[dayGridPlugin, interactionPlugin,timeGridPlugin,googleCalendarPlugin]}
googleCalendarApiKey=API_KEY
initialView="dayGridMonth"
weekends={true}
dateClick={handleDateClick}
headerToolbar={false}
eventSources = {[{
googleCalendarId : '[email protected]'
}]}
height='70vh' />`
I’ve ensured that my Google Calendar is set to public, and I’ve replaced ‘YOUR_API_KEY’ and ‘YOUR_GOOGLE_CALENDAR_ID’ with my actual API key and calendar ID respectively. However, no events are being displayed.
I’ve verified that the API key is correct and that the calendar ID points to the correct calendar. Is there something I might be missing or any additional steps I should take to troubleshoot this issue?
Any assistance would be greatly appreciated. Thank you.
Saud Ahmad is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.