// import React...importReactfrom'react'import{render}from'react-dom'// ... and sardius-fullcalendar-wrapper.importFullCalendarfrom'sardius-fullcalendar-wrapper'// ... and any fullcalendar plugins you may requireimportinteractionPluginfrom'@fullcalendar/interaction'importdayGridPluginfrom'@fullcalendar/daygrid'// ... and any fullcalendar specific cssimport'@fullcalendar/core/main.css'import'@fullcalendar/daygrid/main.css'consttoday=newDate()consttomorrow=newDate()classExampleComponentextendsReact.Component{constructor(props){super(props)// Create a reference to the component to use Full Calendar methodsthis.calendarApiRef=React.createRef()this.state={events: [{title: 'Example Event',start: today},{title: 'Example Event',start: tomorrow.setDate(today.getDate()+1)}]}}eventClicked=(eventClickInfo)=>{alert('Event has been clicked!')}getView=()=>{// Use reference to call Full Calendar Methodsconstview=this.calendarApiRef.current.calendar.getView()alert('We are using FullCalendar Methods!')}selectEvent=(selectionInfo)=>{alert('Event Selected!')}render(){return(<FullCalendarref={this.calendarApiRef}nowIndicatorheader={{left: 'prev,today,next',center: 'title',right: 'dayGridMonth, dayGridWeek, dayGridDay'}}navLinksevents={this.state.events}select={selectionInfo=>{this.selectEvent(selectionInfo)}}// Another example of a callback / handler functioneventClick={eventClickInfo=>{this.eventClicked(eventClickInfo)}}plugins={[interactionPlugin,dayGridPlugin]}editableselectablesnapDuration="00:05"allDaySlot={false}defaultView="dayGridMonth"/>)}};render(<ExampleComponent/>,document.getElementById('root'))