From a237f8fef4f9634b556c2d23b9d7d6a26925ef7e Mon Sep 17 00:00:00 2001 From: zhangchen Date: Mon, 6 Apr 2020 16:47:02 +0800 Subject: [PATCH] fix(parser): "checkInFor" should search up to inline-template --- src/compiler/parser/index.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/compiler/parser/index.js b/src/compiler/parser/index.js index 4debf62a1f4..45d4b4b37f3 100644 --- a/src/compiler/parser/index.js +++ b/src/compiler/parser/index.js @@ -895,9 +895,8 @@ function processAttrs (el) { function checkInFor (el: ASTElement): boolean { let parent = el while (parent) { - if (parent.for !== undefined) { - return true - } + if (parent.attrsMap['inline-template'] != null) return false; + if (parent.for !== undefined) return true; parent = parent.parent } return false