File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
packages/app-backend-core/src Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -221,6 +221,16 @@ export async function removeApp (app: App, ctx: BackendContext) {
221
221
}
222
222
}
223
223
224
+ // eslint-disable-next-line camelcase
225
+ function _legacy_getVueFromApp ( app ) {
226
+ if ( app . constructor . name === 'VueComponent' ) {
227
+ // When Vue.extend is used the component is an instance of VueComponent instead of Vue.
228
+ // VueComponent has a property super which points to the original Vue constructor
229
+ return app . constructor . super
230
+ }
231
+ return app . constructor
232
+ }
233
+
224
234
// eslint-disable-next-line camelcase
225
235
export async function _legacy_getAndRegisterApps ( ctx : BackendContext ) {
226
236
// Remove apps that are legacy
@@ -232,7 +242,7 @@ export async function _legacy_getAndRegisterApps (ctx: BackendContext) {
232
242
233
243
const apps = scan ( )
234
244
apps . forEach ( app => {
235
- const Vue = app . constructor
245
+ const Vue = _legacy_getVueFromApp ( app )
236
246
registerApp ( {
237
247
app,
238
248
types : { } ,
You can’t perform that action at this time.
0 commit comments