mdbook-rustdoc-link
For best results, view this page at https://tonywu6.github.io/mdbookkit/rustdoc-link.
rustdoc-style linking for mdBook (with the help of rust-analyzer).
You write:
The [`option`][std::option] and [`result`][std::result] modules define optional and
error-handling types, [`Option<T>`] and [`Result<T, E>`]. The [`iter`][std::iter] module
defines Rust's iterator trait, [`Iterator`], which works with the `for` loop to access
collections. [^1]
You get:
The option
and result
modules define optional and
error-handling types, Option<T>
and Result<T, E>
. The iter
module
defines Rust's iterator trait, Iterator
, which works with the for
loop to access
collections. 1
mdbook-rustdoc-link
is an mdBook preprocessor. Using rust-analyzer, it converts type
names, module paths, and so on, into links to online crate docs. No more finding and
pasting URLs by hand.
Overview
To get started, simply follow the quickstart guide!
If you would like to read more about this crate:
For writing documentation —
- To learn more about how it is resolving items into links, including feature-gated items, see Name resolution.
- To know how to link to other types of items like functions, macros, and implementors, see Supported syntax.
For adapting this crate to your project —
- If you use Cargo workspaces, see specific instructions in Workspace layout.
- If you are working on a large project, and processing is taking a long time, see the discussion in Caching.
For additional usage information —
- You can use this as a standalone command line tool: see Standalone usage.
- For tips on using this in CI, see Continuous integration.
- For all available options and how to set them, see Configuration.
- Finally, review Known issues and limitations.
Happy linking!
License
This project is released under the Apache 2.0 License and the MIT License.
-
Text adapted from A Tour of The Rust Standard Library ↩