mirror of
https://github.com/servo/servo.git
synced 2025-07-23 23:33:43 +01:00
script: Implement Element::GetHTML
and ShadowRoot::GetHTML
(#36106)
* Serialize html fragments without going through html5ever Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Implement ShadowRoot::GetHtml / Element::GetHtml Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Update WPT expectations Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Propagate CanGc annotations Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
parent
1c9f486f88
commit
19d5f5f06f
12 changed files with 286 additions and 15941 deletions
|
@ -804,7 +804,7 @@ pub(crate) fn handle_get_page_source(
|
|||
.find_document(pipeline)
|
||||
.ok_or(ErrorStatus::UnknownError)
|
||||
.and_then(|document| match document.GetDocumentElement() {
|
||||
Some(element) => match element.GetOuterHTML() {
|
||||
Some(element) => match element.GetOuterHTML(can_gc) {
|
||||
Ok(source) => Ok(source.to_string()),
|
||||
Err(_) => {
|
||||
match XMLSerializer::new(document.window(), None, can_gc)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue