Skip to content

Commit d25cb29

Browse files
committed
Make _template an actual <template>, for correctness.
1 parent 75a9a5f commit d25cb29

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/lib/template/templatizer.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -198,10 +198,10 @@
198198
},
199199

200200
_customPrepAnnotations: function(archetype, template) {
201-
// Don't store the actual template instance to avoid leaking; just
202-
// store an object referencing its content
203-
archetype._template = {_content: template._content};
204-
var c = template._content;
201+
// Store a "clone" of the template on the archetype (content has been
202+
// pulled into _content property, so copy that also)
203+
var t = archetype._template = document.createElement('template');
204+
var c = t._content = template._content;
205205
if (!c._notes) {
206206
var rootDataHost = archetype._rootDataHost;
207207
if (rootDataHost) {

0 commit comments

Comments
 (0)