diff --git a/src/viewer.js b/src/viewer.js index 290cabe91d7..b6c43b2cf1b 100644 --- a/src/viewer.js +++ b/src/viewer.js @@ -20,7 +20,6 @@ * */ -import ViewerComponent from './components/ViewerComponent.vue' import { logger } from './helpers/logger.js' import { openMimetypesMarkdown, openMimetypesPlainText } from './helpers/mime.js' @@ -33,8 +32,7 @@ if (typeof OCA.Viewer === 'undefined') { OCA.Viewer.registerHandler({ id: 'text', mimes: [...openMimetypesMarkdown, ...openMimetypesPlainText], - // Would be good to be able to lazyload that - component: ViewerComponent, + component: () => import('./components/ViewerComponent.vue'), group: null, theme: 'default', canCompare: true,