pub(crate) fn emit(doc_root: &Path) -> Result<()>Expand description
Write the landing page and OpenAPI assets into doc_root
(normally target/doc/).
Called by cargo xtask doc after a successful cargo doc run — including
-p partial builds, where crate links into undocumented crates will 404
locally until a full workspace build fills them in. Emitting
unconditionally keeps the output deterministic: the page is derived from
cargo metadata, not from whichever subset happened to be built.