PHPackages                             benjaminhoegh/parsedown-toc - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. benjaminhoegh/parsedown-toc

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

benjaminhoegh/parsedown-toc
===========================

Table of Contents Extension for Parsedown.

v1.5.4(1y ago)2133.6k↓37.1%53MITPHPPHP &gt;=7.4CI passing

Since Aug 19Pushed 1y ago2 watchersCompare

[ Source](https://github.com/BenjaminHoegh/parsedownToc)[ Packagist](https://packagist.org/packages/benjaminhoegh/parsedown-toc)[ Docs](https://github.com/BenjaminHoegh/parsedownToc/)[ Fund](https://paypal.me/BenjaminHoegh)[ Fund](https://www.buymeacoffee.com/BenjaminHoegh)[ RSS](/packages/benjaminhoegh-parsedown-toc/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (3)Versions (12)Used By (3)

 [ ![ParsedownToc](https://github.com/BenjaminHoegh/ParsedownToc/raw/master/.github/parsedownToc.png) ](https://github.com/BenjaminHoegh/ParsedownToc)

ParsedownToc
============

[](#parsedowntoc)

[![GitHub release](https://camo.githubusercontent.com/fbd6cd88ea08b9db7e89d0ca7a5168381d63129cc85450096f800bf134089a51/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f42656e6a616d696e486f6567682f5061727365646f776e546f632e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/fbd6cd88ea08b9db7e89d0ca7a5168381d63129cc85450096f800bf134089a51/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f42656e6a616d696e486f6567682f5061727365646f776e546f632e7376673f7374796c653d666c61742d737175617265)[![GitHub](https://camo.githubusercontent.com/04d27d7f434db4c300082605242eb64eae6f2a70a1cb65df3ae56c71f4e8e395/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f42656e6a616d696e486f6567682f5061727365646f776e546f632e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/04d27d7f434db4c300082605242eb64eae6f2a70a1cb65df3ae56c71f4e8e395/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f42656e6a616d696e486f6567682f5061727365646f776e546f632e7376673f7374796c653d666c61742d737175617265)

**ParsedownToc** is an extension for Parsedown and ParsedownExtra that introduces advanced features for developers working with Markdown. It is based on [@KEINOS toc extention](https://github.com/KEINOS/parsedown-extension_table-of-contents)

Note

Does not yet include the latest changes in ParsedownExtended v1.2.0

Features:
---------

[](#features)

- **Speed:** Super-fast processing.
- **Configurability:** Easily customizable for different use-cases.
- **Custom Header IDs:** Full support for custom header ids.

Prerequisites:
--------------

[](#prerequisites)

- Requires Parsedown 1.7.4 or later.

Installation:
-------------

[](#installation)

Ensure you have Composer installed on your system.

1. Install the ParsedownToc package using Composer:

    ```
    composer require benjaminhoegh/ParsedownToc
    ```
2. Alternatively, you can download the [latest release](https://github.com/BenjaminHoegh/ParsedownToc/releases/latest) and include `Parsedown.php` in your project.

Usage:
------

[](#usage)

### Basic example:

[](#basic-example)

```
