viewer
viewer copied to clipboard
Support asynchronous components
It would be great if a callback that would return a promise could be provided to the registerHandler function so that the component would only be loaded if it is actually required. Basically something like this:
OCA.Viewer.registerHandler({
id: 'richdocuments',
group: null,
mimes: supportedMimes,
component: () => import('./Office.vue')
})
https://vuejs.org/v2/guide/components-dynamic-async.html#Async-Components
Well, how can I do that? :p
I'm just using the :is
vue attribute, I would assume it would work out of the box :see_no_evil:
Hm not sure, all i know is that is was not working as expected, but I'll investigate myself a bit when I find some more time.