Vue Scheduler - View Switcher

View switcher is a scheduler element used for quick switching between views.

View Switcher

To specify what views are available within the switcher, use the views property.

App.vue
  • <template>
  • <DxScheduler
  • :views="views"
  • />
  • </template>
  •  
  • <script>
  • import 'devextreme/dist/css/dx.light.css';
  •  
  • import DxScheduler from 'devextreme-vue/scheduler';
  •  
  • export default {
  • components: {
  • DxScheduler
  • },
  • data() {
  • return {
  • views: ['day', 'week', 'agenda']
  • }
  • }
  • }
  • </script>

On mobile devices, the view switcher is displayed as a drop-down menu.

Drop-down View Switcher

To use the drop-down menu on all types of devices, assign true to the useDropDownViewSwitcher property; to use tabs - assign false.

App.vue
  • <template>
  • <DxScheduler
  • :use-drop-down-view-switcher="true" />
  • </template>
  •  
  • <script>
  • import 'devextreme/dist/css/dx.light.css';
  •  
  • import DxScheduler from 'devextreme-vue/scheduler';
  •  
  • export default {
  • components: {
  • DxScheduler
  • }
  • }
  • </script>
See Also