globalComponents.ts 927 B

1234567891011121314151617181920212223242526
  1. // Copyright (C) 2012-2023 Zammad Foundation, https://zammad-foundation.org/
  2. import type { App } from 'vue'
  3. import type { FormKit } from '@formkit/vue'
  4. import CommonIcon from '@shared/components/CommonIcon/CommonIcon.vue'
  5. import CommonLink from '@shared/components/CommonLink/CommonLink.vue'
  6. import CommonDateTime from '@shared/components/CommonDateTime/CommonDateTime.vue'
  7. import type { RouterLink, RouterView } from 'vue-router'
  8. declare module '@vue/runtime-core' {
  9. export interface GlobalComponents {
  10. CommonIcon: typeof CommonIcon
  11. CommonLink: typeof CommonLink
  12. CommonDateTime: typeof CommonDateTime
  13. FormKit: typeof FormKit
  14. RouterView: typeof RouterView
  15. RouterLink: typeof RouterLink
  16. }
  17. }
  18. export default function initializeGlobalComponents(app: App): void {
  19. app.component('CommonIcon', CommonIcon)
  20. app.component('CommonLink', CommonLink)
  21. app.component('CommonDateTime', CommonDateTime)
  22. }