Skip to content

Commit

Permalink
Merge branch 'legacy-undefined-noBatch' into legach-undefined-noBatch…
Browse files Browse the repository at this point in the history
…-opt
  • Loading branch information
kevinpschaaf committed Sep 18, 2019
2 parents a7866b3 + 042d95b commit 50dbf55
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions lib/utils/templatize.js
Original file line number Diff line number Diff line change
Expand Up @@ -392,21 +392,31 @@ function addPropagateEffects(target, templateInfo, options, methodHost) {
* @constructor
* @extends {DataTemplate}
*/
let templatizedBase = options.mutableData ? MutableDataTemplate : DataTemplate;
let templatizedBase =
options.mutableData ? MutableDataTemplate : DataTemplate;

// NOTE: due to https://github.com/google/closure-compiler/issues/2928,
// combining the next two lines into one assignment causes a spurious
// type error.
/** @private */
klass = templateInfo.templatizeTemplateClass =
class TemplatizedTemplate extends templatizedBase {};
class TemplatizedTemplate extends templatizedBase {}
klass = templateInfo.templatizeTemplateClass = TemplatizedTemplate;
} else {
/**
* @constructor
* @extends {PolymerElement}
*/
const templatizedBase = target.constructor;

// Create a cached subclass of the base custom element class onto which
// to put the template-specific propagate effects
// NOTE: due to https://github.com/google/closure-compiler/issues/2928,
// combining the next two lines into one assignment causes a spurious
// type error.
/** @private */
class TemplatizedTemplateExtension extends templatizedBase {}
klass = templateInfo.templatizeTemplateClass =
class TemplatizedTemplateExtension extends templatizedBase {};
TemplatizedTemplateExtension;
}
// Add template - >instances effects
// and host <- template effects
Expand Down

0 comments on commit 50dbf55

Please sign in to comment.