mirror of https://github.com/luizdepra/hugo-coder.git

John D. Rowell
2 days ago 145401dd6b9161e1316a338ca54f3a35d8d696d0
refs
author John D. Rowell <me@jdrowell.com>
Monday, February 23, 2026 15:28 +0100
committer GitHub <noreply@github.com>
Monday, February 23, 2026 15:28 +0100
commit145401dd6b9161e1316a338ca54f3a35d8d696d0
tree c8f11ccc6aef403dd3a2b9d07df5b7a669da0f5d tree | zip | gz
parent cb13ec4671611990420f29321c4430e928a67518 view | diff
Added TOC support (#985)

### Prerequisites

Put an `x` into the box(es) that apply:

- [ ] This pull request fixes a bug.
- [x] This pull request adds a feature.
- [ ] This pull request introduces breaking change.

### Description

Adds "Table of Contents" functionality for posts. I believe this was not
implemented before, and I use it on my site.

### Issues Resolved

List any existing issues this pull request resolves.

### Checklist

Put an `x` into the box(es) that apply:

#### General

- [x] Describe what changes are being made
- [x] Explain why and how the changes were necessary and implemented
respectively
- [ ] Reference issue with `#<ISSUE_NO>` if applicable

#### Resources

- [ ] If you have changed any SCSS code, run `make release` to
regenerate all CSS files

#### Contributors

- [x] Add yourself to `CONTRIBUTORS.md` if you aren't on it already
2 files modified
1 files added
14 ■■■■■ changed files
i18n/en.toml 3 ●●●●● diff | view | raw | blame | history
layouts/_partials/toc.html 9 ●●●●● diff | view | raw | blame | history
layouts/posts/single.html 2 ●●●●● diff | view | raw | blame | history