Просмотр исходного кода

fix(compiler-core): use `isProp.arg.loc` instead of `isProp.loc` (#11547)

山吹色御守 1 год назад
Родитель
Сommit
236fb7abeb
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      packages/compiler-core/src/transforms/transformElement.ts

+ 1 - 1
packages/compiler-core/src/transforms/transformElement.ts

@@ -250,7 +250,7 @@ export function resolveComponentType(
         exp = isProp.exp
         if (!exp) {
           // #10469 handle :is shorthand
-          exp = createSimpleExpression(`is`, false, isProp.loc)
+          exp = createSimpleExpression(`is`, false, isProp.arg!.loc)
           if (!__BROWSER__) {
             exp = isProp.exp = processExpression(exp, context)
           }