index.ts 603 B

123456789101112131415161718
  1. // Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. import mainInitializeApolloClient from '#shared/server/apollo/index.ts'
  3. import type {
  4. InitializeAppApolloClient,
  5. CacheInitializerModules,
  6. } from '#shared/types/server/apollo/client.ts'
  7. import type { App } from 'vue'
  8. export const cacheInitializerModules: CacheInitializerModules =
  9. import.meta.glob('./cache/initializer/*.ts', { eager: true })
  10. const initializeApolloClient: InitializeAppApolloClient = (app: App) => {
  11. mainInitializeApolloClient(app, cacheInitializerModules)
  12. }
  13. export default initializeApolloClient