Only month view in fullcalendar (remove/Hide “Day” and “Weeks” view)

前端 未结 2 1362
旧时难觅i
旧时难觅i 2021-02-20 10:09

My fullcalendar has - \"Month|Week|Day\" view , I want to remove or hide the \"Week\" and \"Day\" views as we have been using only \"Month\" View.

Can you please tell me

2条回答
  •  伪装坚强ぢ
    2021-02-20 10:34

    When you start fullcalendar, don't include agendayDay and agendaWeek. Something like

    $('#calendar').fullCalendar({
        header: {
            left: 'prev,next',
            center: 'title',
            right: 'month'
        }
    });
    

    Update: To get rid of the month button:

    $('#calendar').fullCalendar({
        header: {
            left: 'prev,next',
            center: 'title',
            right: ''
        }
    });
    

提交回复
热议问题