FullCalendar Documentation
repository·main·Indexed 40 days ago
https://github.com/fullcalendar/fullcalendar-docsOfficial documentation for the FullCalendar project, including guides on event objects, event sources (JSON feeds, Google Calendar, and custom functions), and API callbacks like eventClick.
What's inside FullCalendar
- FullCalendar supports multiple ways to load and manage event data. You can provide events as a static array, a JSON feed, or via a function. Once loaded, events can be dynamically manipulated using various methods to update, remove, or refetch them. The system also supports advanced event requesting (lazy fetching) and data parsing/transformation to ensure your data matches the expected calendar format.
Control Resource Display in FullCalendar
mainThe Resource Display feature allows you to control the visual aspects of resources within FullCalendar views (such as Timeline or Vertical Resource views). This includes managing resource ordering, filtering resources based on events, and customizing the text or rendering of resource elements.
Note: This feature is part of the Premium version of FullCalendar.
Use Resource Display features
mainResource Display allows you to control the visual aspects of resources in FullCalendar, including their ordering and text content. Note that these features are part of the premium offering.
Key capabilities include:
- Ordering: Customizing the sequence in which resources appear.
- Filtering: Controlling which resources are displayed based on event presence.
- Custom Rendering: Using render hooks to modify the appearance and lifecycle of resource labels and lanes.
Use Resource Data in FullCalendar
mainResource Data allows you to define specific entities (like rooms, employees, or equipment) that events can be assigned to. This enables resource-based views such as Resource Timeline or Resource Day. You can populate the calendar with resources using several methods: providing a static array, a JSON feed, or a function that returns data. Once loaded, you can manipulate this data using the Calendar API methods.Get started with FullCalendar Scheduler
mainFullCalendar Scheduler is a separate collection of premium plugins available for FullCalendar. These require a different setup process than the standard open-source plugins.Control event appearance in FullCalendar
mainYou can customize the visual appearance of events in FullCalendar using a variety of configuration options. These options allow you to control colors (background, border, and text), time formatting, and how event details (like end times) are displayed. Additionally, you can use render hooks to inject custom HTML, CSS classes, or lifecycle logic into individual events.Configure Date Navigation in FullCalendar
mainFullCalendar provides several settings and methods to control and manipulate the current dates displayed in a view.
Configuration Settings
You can control the initial state and behavior of date navigation using these settings:
defaultDate: Sets the initial date shown when the calendar is first loaded.dateIncrement: Defines how much the date changes when using increment/decrement methods.dateAlignment: Determines how dates are aligned within the view.validRange: Restricts the range of dates that can be navigated to (e.g., preventing users from navigating to the past or far future).
Navigation Methods
You can programmatically navigate the calendar using the following methods:
calendar.prev(): Move to the previous period (day, week, month, etc., depending on the current view).calendar.next(): Move to the next period.calendar.prevYear(): Move back one year.calendar.nextYear(): Move forward one year.calendar.today(): Jump to the current date.calendar.gotoDate(date): Jump to a specific date.calendar.incrementDate(amount): Increment the current date by a specific amount.calendar.getDate(): Retrieve the current date being displayed in the view.
Control the dimensions of the FullCalendar instance
mainFullCalendar provides several configuration options to manage its dimensions, including height, content height, and aspect ratio. You can control whether the calendar fills its container, maintains a specific ratio, or expands based on its content.Manage view dates with Date Navigation methods and settings
mainFullCalendar provides a set of methods and settings to control and query the current dates displayed in a view. This includes navigating between periods (prev/next), jumping to specific dates (gotoDate, today), and adjusting the date increment or alignment.
Key configuration settings include:
defaultDate: Sets the initial date for the view.dateIncrement: Determines how much the date changes when navigating.dateAlignment: Controls how dates are aligned within the view.validRange: Restricts the range of dates the calendar can navigate to.
Key methods include:
prev()/next(): Move to the previous or next period.prevYear()/nextYear(): Move to the previous or next year.today(): Jump to the current system date.gotoDate(date): Jump to a specific date.incrementDate(amount, unit): Increment the current date by a specific amount and unit.getDate(): Retrieve the current date of the view.
Interact with the current view using the View API
mainFullCalendar provides a suite of settings, methods, and callbacks to manage and interact with the active view. The View API allows you to:
- Configure the
defaultView. - Access the current
view-object. - Use methods like
Calendar.changeViewto switch between different view types. - Utilize lifecycle callbacks such as
viewSkeletonRender,viewSkeletonDestroy,datesRender, anddatesDestroyto perform custom logic when views or dates are rendered or removed.
- Configure the
Customize Resource Display in FullCalendar
mainFullCalendar provides premium features to control the visual aspects of resources in Timeline and Resource views. You can customize resource ordering, filter resources based on event presence, and use render hooks to manipulate the DOM or content of resource labels and lanes.What is the Scheduler Plugin?
mainThe Scheduler plugin is a premium extension for FullCalendar that adds two specialized views for managing resources (e.g., rooms, staff, or equipment):
- Timeline View: Optimized for displaying a large number of resources.
- Vertical Resource View: Optimized for displaying a smaller number of resources.
Note: Scheduler is a premium plugin and requires a separate license from the core FullCalendar library.