rustdoc: remove `type="text/css" from stylesheet links
MDN directly recommends this in <https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link>,
since "CSS is the only stylesheet language used on the web."
Like 07a243b2a4
, but a few places that were
missed the first time.
This commit is contained in:
parent
37d7de3379
commit
46b4a3b831
3 changed files with 2 additions and 3 deletions
|
@ -637,7 +637,7 @@ impl<'tcx> FormatRenderer<'tcx> for Context<'tcx> {
|
||||||
You need to enable Javascript be able to update your settings.\
|
You need to enable Javascript be able to update your settings.\
|
||||||
</section>\
|
</section>\
|
||||||
</noscript>\
|
</noscript>\
|
||||||
<link rel=\"stylesheet\" type=\"text/css\" \
|
<link rel=\"stylesheet\" \
|
||||||
href=\"{static_root_path}{settings_css}\">\
|
href=\"{static_root_path}{settings_css}\">\
|
||||||
<script defer src=\"{static_root_path}{settings_js}\"></script>",
|
<script defer src=\"{static_root_path}{settings_js}\"></script>",
|
||||||
static_root_path = page.get_static_root_path(),
|
static_root_path = page.get_static_root_path(),
|
||||||
|
|
|
@ -184,7 +184,6 @@ function browserSupportsHistoryApi() {
|
||||||
function loadCss(cssUrl) {
|
function loadCss(cssUrl) {
|
||||||
const link = document.createElement("link");
|
const link = document.createElement("link");
|
||||||
link.href = cssUrl;
|
link.href = cssUrl;
|
||||||
link.type = "text/css";
|
|
||||||
link.rel = "stylesheet";
|
link.rel = "stylesheet";
|
||||||
document.getElementsByTagName("head")[0].appendChild(link);
|
document.getElementsByTagName("head")[0].appendChild(link);
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,7 +53,7 @@ pub(crate) fn render<P: AsRef<Path>>(
|
||||||
|
|
||||||
let mut css = String::new();
|
let mut css = String::new();
|
||||||
for name in &options.markdown_css {
|
for name in &options.markdown_css {
|
||||||
write!(css, r#"<link rel="stylesheet" type="text/css" href="{name}">"#)
|
write!(css, r#"<link rel="stylesheet" href="{name}">"#)
|
||||||
.expect("Writing to a String can't fail");
|
.expect("Writing to a String can't fail");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue