From cd3e953a82e9fa9c906ad4433955893952ab5603 Mon Sep 17 00:00:00 2001 From: Raphael Luba Date: Fri, 13 Jul 2018 21:49:34 +0200 Subject: [PATCH] =?UTF-8?q?Don=E2=80=99t=20use=20repeat=E2=80=99s=20fast-p?= =?UTF-8?q?ath=20if=20its=20view=20contains=20custom=20elements?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes aurelia/templating-resources#356 within sub-views --- src/analyze-view-factory.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/analyze-view-factory.ts b/src/analyze-view-factory.ts index c4bf9f4..b639b59 100644 --- a/src/analyze-view-factory.ts +++ b/src/analyze-view-factory.ts @@ -9,7 +9,8 @@ function behaviorRequiresLifecycle(instruction) { let name = t.elementName !== null ? t.elementName : t.attributeName; return lifecycleOptionalBehaviors.indexOf(name) === -1 && (t.handlesAttached || t.handlesBind || t.handlesCreated || t.handlesDetached || t.handlesUnbind) || t.viewFactory && viewsRequireLifecycle(t.viewFactory) - || instruction.viewFactory && viewsRequireLifecycle(instruction.viewFactory); + || instruction.viewFactory && viewsRequireLifecycle(instruction.viewFactory) + || instruction.initiatedByBehavior; } function targetRequiresLifecycle(instruction) {