fix(runtime-core): fix resolving assets from mixins and extends

fix #1963
This commit is contained in:
Evan You
2020-08-26 18:09:54 -04:00
parent bc64c60c7e
commit 0cb7f7f880
4 changed files with 107 additions and 3 deletions

View File

@@ -83,7 +83,8 @@ function resolveAsset(
const res =
// local registration
resolve((Component as ComponentOptions)[type], name) ||
// check instance[type] first for components with mixin or extends.
resolve(instance[type] || (Component as ComponentOptions)[type], name) ||
// global registration
resolve(instance.appContext[type], name)
if (__DEV__ && warnMissing && !res) {