Skip to content

Instantly share code, notes, and snippets.

@arshaw
Last active March 26, 2019 18:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arshaw/3fb1d89f730dc0ef6e5945955595d848 to your computer and use it in GitHub Desktop.
Save arshaw/3fb1d89f730dc0ef6e5945955595d848 to your computer and use it in GitHub Desktop.
class MyApp extends Component {
fullCalendar = React.createRef()
render() {
return (
<div>
<button onClick={ this.handleNext }>goto next</button>
<FullCalendar ref={ this.fullCalendar } />
</div>
)
}
handleNext = () => {
let calendarApi = this.fullCalendar.current.getApi()
calendarApi.next()
}
}
@joshuaRuff
Copy link

I like it, feels really clean.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment