<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../../dist/fullcalendar.css' rel='stylesheet' />
<script src='../../dist/fullcalendar.js'></script>
<script>

  document.addEventListener('DOMContentLoaded', function() {
    var calendarEl = document.getElementById('calendar');

    var calendar = new FullCalendar.Calendar(calendarEl, {
      headerToolbar: {
        left: 'prev,next today',
        center: 'title',
        right: 'dayGridMonth,week,day'
      },
      initialDate: '2018-12-12',
      navLinks: true, // can click day/week names to navigate views
      selectable: true,
      dateClick: function(info) {
        console.log('dateClick', info.dateStr)
      }
    });

    calendar.render();
  });

</script>
<style>

  /*
  for
  https://github.com/fullcalendar/fullcalendar/issues/3615
  */

  html, body {
    height: 100%;
  }

  body {
    border: 1px solid red;
    overflow-x: hidden;
  }

  body {
    margin: 0;
    padding: 0;
    font-family: "Lucida Grande",Helvetica,Arial,Verdana,sans-serif;
    font-size: 13px;
  }

  #calendar {
    width: 900px;
    margin: 40px auto;
  }

</style>
</head>
<body>

  <div id='calendar'></div>

</body>
</html>
