Skip to content

Commit a26247b

Browse files
author
Steven Orvell
committed
Fixes #2010, fixes #1818: Shady dom mutations which trigger additional mutations are now successfully enqueued.
1 parent fb52120 commit a26247b

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎src/mini/shady.html‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,10 @@
129129
_finishDistribute: function() {
130130
// compose self
131131
if (this._useContent) {
132+
// note: it's important to mark this clean before distribution
133+
// so that attachment that provokes additional distribution (e.g.
134+
// adding something to your parentNode) works
135+
this.shadyRoot._distributionClean = true;
132136
if (hasInsertionPoint(this.shadyRoot)) {
133137
this._composeTree();
134138
} else {
@@ -146,7 +150,6 @@
146150
}
147151
}
148152
this.shadyRoot._hasDistributed = true;
149-
this.shadyRoot._distributionClean = true;
150153
}
151154
},
152155

0 commit comments

Comments
 (0)