view property
Defines the view for the SfCalendar.
Defaults to CalendarView.day
.
See also:
- CalendarView, to know about available calendar views.
- SfCalendar.onViewChanged, the callback to notify that the view changed, this also contains the visible dates collection.
- CalendarController.view, to change the calendar view dynamically.
- showDatePickerButton, to show date picker for quickly navigating to a different date.
- allowedViews to show list of calendar views on header view for quick navigation.
- Knowledge base: How to switch between views
Widget build(BuildContext context) {
return Container(
child: SfCalendar(
view: CalendarView.day,
),
);
}
Implementation
final CalendarView view;