Calendar
The VCalendar component is a flexible calendar display that supports multiple view types, event handling, and customizable time ranges.Usage
API
Props
The currently selected date. Can be a date string, timestamp, or Date object.
Calendar display type. Options:
month, week, day, 4day, category, custom-weekly, custom-daily.Array of events to display on the calendar.
Categories for category view mode.
Number of days to show in category view.
Maximum number of days to display.
Hide dynamically created categories.
Show all categories even if they have no events.
Category name for events with invalid categories.
Events
Emitted when the selected date changes.
Emitted when the visible date range changes.
Emitted when navigating to a different time period.
Slots
Customize individual day cells.
Customize the body content of day cells.
Customize the header of day cells.
Customize individual event display.
Customize category rows in category view.
Examples
Week View
Category View
Custom Event Display
Methods
The component exposes several methods through template refs:next(amount?: number)- Navigate forward in timeprev(amount?: number)- Navigate backward in timemove(amount: number)- Move by a specific amount