extensions/toc

CHANGELOG
Edited: Sunday 22 June 2025

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog,
adheres to Semantic Versioning,
and is generated by Changie.

v0.12.0 - 11 May 2025

Added

  • Support ordered lists for table of contents with ‘RenderOrderedList’.

v0.11.0 - 2 February 2025

Changed

  • goldmark: Raise minimum version to v1.7.8. This version of goldmark deprecates Node.Text.

v0.10.0 - 27 February 2024

Added

  • {Extender, Transformer}: Add TitleDepth field to change the level of the Table of Contents heading.

Changed

  • Relicense to BSD3.

v0.9.0 - 24 November 2023

Changed

  • Rename HeadingID option to TitleID. HeadingID is too generic.

v0.8.0 - 24 November 2023

Added

  • Add a HeadingID option to specify a custom ID for the Table of Contents heading.

Changed

  • Table of Contents heading now automatically gets an ID if the Parser was given an IDs generator.

v0.7.0 - 11 September 2023

Added

  • The new MinDepth option allows ignoring headings below the specified level.

v0.6.0 - 11 September 2023

Added

  • The new Compact option removes empty nodes in the TOC. If you have >1 level of difference between headings, this will render a cleaner TOC.

v0.5.0 - 2 September 2023

Added

  • Add a ListID attribute to Extender and Transformer.
    If set, the rendered <ul> will have an id attribute with this value.

v0.4.0 - 2 March 2023

Added

  • Extender: Add Title field to change the Table of Contents title.
  • Inspect: Add MaxDepth option to limit the depth of the Table of Contents.

v0.3.0 - 19 December 2022

Changed

  • Change the module path to go.abhg.dev/goldmark/toc.

v0.2.1 - 15 December 2021

Fixed

  • inspect: Correctly handle escaped punctuation in titles.
  • render: Don’t unintentionally interpret escape sequences in titles.

v0.2.0 - 4 April 2021

Added

  • Add toc.Transformer to generate a table of contents to the front of any
    document parsed by a Goldmark parser.
  • Add toc.Extender to extend a goldmark.Markdown object with the
    transformer.

v0.1.0 - 23 March 2021

  • Initial release.