Skip to content

Commit b8c6eb1

Browse files
committed
Auto merge of #23146 - lifthrasiir:oh-noes-i-broke-rustdoc-sidebars-what-to-do-now, r=Manishearth
We require the *deferred* loading, not just an opportunistic asynchronous loading. (Yes, that was my oversight, as I only checked it locally...) I think `<script defer>` is safe to use, according to <http://caniuse.com/#feat=script-defer>.
2 parents 36cd65f + a3e4a16 commit b8c6eb1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustdoc/html/render.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2247,7 +2247,7 @@ impl<'a> fmt::Display for Sidebar<'a> {
22472247
// there is no sidebar-items.js beyond the crate root path
22482248
// FIXME maybe dynamic crate loading can be merged here
22492249
} else {
2250-
try!(write!(fmt, "<script async src=\"{path}sidebar-items.js\"></script>",
2250+
try!(write!(fmt, "<script defer src=\"{path}sidebar-items.js\"></script>",
22512251
path = relpath));
22522252
}
22532253

0 commit comments

Comments
 (0)