An open API service indexing awesome lists of open source software.

https://github.com/funnyhcat-dotcom/readme-toc-genie

Generate and update Markdown table of contents blocks.
https://github.com/funnyhcat-dotcom/readme-toc-genie

cli developer-tools documentation markdown nodejs readme table-of-contents toc

Last synced: about 10 hours ago
JSON representation

Generate and update Markdown table of contents blocks.

Awesome Lists containing this project

README

          

# readme-toc-genie

Generate and update Markdown table of contents blocks.

A tiny zero-dependency CLI for keeping long README files, docs pages, and guides easy to navigate.

## Quick start

```bash
npx readme-toc-genie README.md
```

```bash
# update README.md in place
npx readme-toc-genie README.md --write

# only include h2 and h3 headings
npx readme-toc-genie docs/guide.md --min-depth 2 --max-depth 3

# JSON for automation
npx readme-toc-genie README.md --format json
```

## Markers

`--write` inserts or updates this block:

```md

...

```

## Features

- GitHub-style heading slugs
- duplicate heading handling
- ignores headings inside fenced code blocks
- configurable min/max heading depth
- markdown and json output

## License

MIT