Table of contents within a chapter

Open
#15 0 comments 0 reactions 1 assignee View on GitHub

@ehuss is already working on this.

Since Oct 22, 2025.

Assessment

This issue has not been assessed yet.

Description

Enhancement Formatting

Originally filed by @simonsapin at https://github.com/rust-lang/rust/issues/40087

It looks like https://doc.rust-lang.org/nightly/reference.html hasn’t been updated yet as of this writing, but in my local copy of the docs reference.html says “We've split up the reference into chapters. Please find it at its new home here.” with a link to reference/index.html.

This new format has a side bar with a table of content, but that ToC has coarser granularity than it used to. As far as I can tell, it has a link for each “chapter” (part of the book that requires navigation to another URL), but I can’t find a ToC for sections within a chapter. reference/expressions.html for example has many sub-sections, to a per-chapter ToC would help a lot.

This is probably a feature request for tool that generates this kind of documentation, but I’m not sure what it is. I’ve vaguely heard of rustboot and mdbook, is this one on these? Are they related? Which issue tracker should be used?

CC @steveklabnik

Dominant language
Rust
Stars
1.6k
Forks
607
Avg merge
1d 1h
Merged PRs (30d)
12

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from rust-lang/reference

All issues in rust-lang/reference

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.