We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b30022a commit c1a6f17Copy full SHA for c1a6f17
src/librustdoc/html/render.rs
@@ -451,6 +451,14 @@ pub fn run(mut krate: clean::Crate,
451
css_file_extension: css_file_extension.clone(),
452
};
453
454
+ // If user passed in `--playground-url` arg, we fill in crate name here
455
+ markdown::PLAYGROUND.with(|slot| {
456
+ if slot.borrow().is_some() {
457
+ let url = slot.borrow().as_ref().unwrap().1.clone();
458
+ *slot.borrow_mut() = Some((Some(krate.name.clone()), url));
459
+ }
460
+ });
461
+
462
// Crawl the crate attributes looking for attributes which control how we're
463
// going to emit HTML
464
if let Some(attrs) = krate.module.as_ref().map(|m| &m.attrs) {
0 commit comments