Dhtmlx Event Calendar 付费版使用

TypeScript 复制代码
<template>
  <div ref="eventCalendarRef" class="event-calendar"></div>
</template>

<script lang="ts" setup>
import { onMounted, ref } from "vue";
// @ts-ignore
import { eventCalendar } from "./lib/event-calendar.dev.js";
import "./lib/event-calendar.css";
import { eventCalendarProps } from "./event-calendar";
defineOptions({ name: "EventCalendar" });
const {
  events,
  date,
  config,
  locale,
  mode,
  calendars,
  colors,
  editorConfig,
  editorValidation,
} = defineProps(eventCalendarProps);
const eventCalendarRef = ref();
const eventCalendarInstance = ref();
const { EventCalendar } = eventCalendar;
onMounted(() => {
  eventCalendarInstance.value = new EventCalendar(eventCalendarRef.value, {
    config: config,
    events: events,
    calendars: calendars,
    date: date,
    mode: mode,
    colors: colors,
    editorConfig: editorConfig,
    editorValidation: editorValidation,
    locale: eventCalendar[locale],
  });
});

defineExpose({
  instance: eventCalendarInstance,
});
</script>

<style lang="scss" scoped>
</style>
相关推荐
coding随想21 分钟前
掌控网页的魔法之书:JavaScript DOM的奇幻之旅
开发语言·javascript·ecmascript
然我1 小时前
不用 Redux 也能全局状态管理?看我用 useReducer+Context 搞个 Todo 应用
前端·javascript·react.js
前端小巷子1 小时前
Web 实时通信:从短轮询到 WebSocket
前端·javascript·面试
DanB242 小时前
html复习
javascript·microsoft·html
呼啦啦呼啦啦啦啦啦啦8 小时前
利用pdfjs实现的pdf预览简单demo(包含翻页功能)
android·javascript·pdf
前端 贾公子10 小时前
vue-cli 模式下安装 uni-ui
前端·javascript·windows
拾光拾趣录10 小时前
链表合并:双指针与递归
前端·javascript·算法
拼图20910 小时前
element-plus——图标推荐
javascript·vue.js·elementui
期待のcode11 小时前
图片上传实现
java·前端·javascript·数据库·servlet·交互
koooo~11 小时前
JavaScript中的Window对象
开发语言·javascript·ecmascript