attribute value escaping

This commit is contained in:
Greg Johnston 2024-03-19 19:58:04 -04:00
parent 2bc04444e1
commit 5ea314c998
3 changed files with 3 additions and 4 deletions

View File

@ -728,7 +728,6 @@ where
req_parts,
default_res_options,
);
println!("providing additional contexts");
add_context();
// run app

View File

@ -14,6 +14,7 @@ oco = { workspace = true, optional = true }
once_cell = "1"
paste = "1"
wasm-bindgen = "0.2"
html-escape = "0.2"
js-sys = "0.3"
web-sys = { version = "0.3", features = [
"Window",

View File

@ -94,7 +94,7 @@ where
buf.push(' ');
buf.push_str(key);
buf.push_str("=\"");
buf.push_str(&escape_attr(V));
buf.push_str(V);
buf.push('"');
}
@ -289,7 +289,6 @@ where
}
}
// TODO
fn escape_attr(value: &str) -> Cow<'_, str> {
value.into()
html_escape::encode_double_quoted_attribute(value)
}