fullcalendar

Fullcalendar: start day at 8AM instead of midnight


We are use the Fullcalendar plugin for booking our events

Al lot of the events take place around midnight so often we see events starting at 22:00 and ending at 4:00. It is possible to insert these in Fullcalendar in the week view but it is a little tricky. It would make more sense to us to start the days at 8 in the morning and end at 8 in the morning so events will usually be visible in a single day.

I did not find this option in the documentation, so I would like to know if there is an existing implementation that does this job or else find a hint where I would start to enhance Fullcalendar to make this possible.


Solution

  • It is possible using the minTime and maxTime by setting them as the following.

    minTime: "08:00:00",
    maxTime: "32:00:00",
    

    Here is a codepen showing this.

    However it is quite buggy. If you try to put a small event into the time that would be the next day after 12PM, then the calendar does not really know what to do and the even will be be out of view. If the event is at least long enough to bring it to the next day past 8AM then it will be visible across both days. Due to the bugs with this method I would suggest using the calendar with its default minTime and maxTimes is the best approach.