Pau Table of Contents Block
This plugin is a Gutenberg block that takes a collection of posts organized by category (book name) and subcategories (chapter names) and creates a table of contents from them. You simply choose the root category to use, and the plugin does the rest. Once the table of contents is made, you can sort the chapters and posts, and the plugin will remember the order. The plugin also creates links to the next and previous posts.
Source Code
The Pau Table of Contents Block is a Gutenberg block created as recommended in the Block Editor Handbook (https://developer.wordpress.org/block-editor/). As recommended by the handbook, the source code is minified by the build process for production. In keeping with the spirit of open source, the unminified code for Pau Table of Contents is available at GitHub (https://github.com/paustian/pau-table-of-contents-block/).
If you want to see an example of this used on a live site, check out my textbook Through the Microscope (https://textbookconsortia.com/through-the-microscope-table-of-contents/)
Minimum Requirements
- WordPress version 6.8 or greater.
- PHP version 7.4 or greater
- MySQL version 5.7 or greater.
Recommended Requirements
- Latest WordPress version.
- PHP version 8.0 or greater.
- MySQL version 8.0 or greater, or MariaDB 10.5 or greater.