switch to comments as placeholder nodes (#2579)
This commit is contained in:
1 parent
30f6986283
commit
4cab834640
8 files changed
+29
-24
No files matched your search
@@ -46,6 +46,7 @@ features = [
|
||||
"HtmlTextAreaElement",
|
||||
"HtmlFormElement",
|
||||
"Text",
|
||||
"Comment",
|
||||
"Window",
|
||||
"DataTransfer",
|
||||
"console",
|
||||
|
||||
@@ -44,9 +44,8 @@ impl WebsysDom {
|
||||
}
|
||||
Text { text } => self.document.create_text_node(text).dyn_into().unwrap(),
|
||||
Dynamic { .. } => {
|
||||
let el = self.document.create_element("pre").unwrap();
|
||||
let _ = el.toggle_attribute("hidden");
|
||||
el.dyn_into().unwrap()
|
||||
let placeholder = self.document.create_comment("placeholder");
|
||||
placeholder.dyn_into().unwrap()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user