Skip to content

Commit 6829c86

Browse files
authored
Remove data-element attribute (#440)
* build: upgrade dom requirement and loosen version range * docs: update examples * feature: trim whitespace when there are only template children closes #363 * maintenance: phpstorm analysis improvements * feature: remove unbound elements that are marked accordingly closes #438 * test: ensure element does not get removed after bound for #438 * feature: use `data-element` attribute for #438 * tweak: remove data-element attribute
1 parent ad208ed commit 6829c86

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/DocumentBinder.php

+4
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,10 @@ public function cleanupDocument():void {
151151

152152
$item->ownerElement->removeAttribute($item->name);
153153
}
154+
155+
foreach($this->document->querySelectorAll("[data-element]") as $dataElement) {
156+
$dataElement->removeAttribute("data-element");
157+
}
154158
}
155159

156160
private function bind(

0 commit comments

Comments
 (0)