diff --git a/lib/utils/templatize.html b/lib/utils/templatize.html index fad92ff748..dbd69d4505 100644 --- a/lib/utils/templatize.html +++ b/lib/utils/templatize.html @@ -77,7 +77,8 @@ children.push(n); n.__templatizeInstance = this; } - if (this.__templatizeOwner.__hideTemplateChildren__) { + if (this.__templatizeOwner && + this.__templatizeOwner.__hideTemplateChildren__) { this._showHideChildren(true); } // Flush props only when props are passed if instance props exist @@ -96,15 +97,13 @@ */ _configureProperties(props) { let options = this.__templatizeOptions; - if (props) { - for (let iprop in options.instanceProps) { - if (iprop in props) { - this._setPendingProperty(iprop, props[iprop]); - } + if (options.forwardHostProp) { + for (let hprop in this.__hostProps) { + this._setPendingProperty(hprop, this.__dataHost['_host_' + hprop]); } } - for (let hprop in this.__hostProps) { - this._setPendingProperty(hprop, this.__dataHost['_host_' + hprop]); + for (let iprop in props) { + this._setPendingProperty(iprop, props[iprop]); } } /** @@ -464,7 +463,8 @@ throw new Error('A