table-of-contents icon indicating copy to clipboard operation
table-of-contents copied to clipboard

fix generated TOC

Open trepmal opened this issue 3 years ago • 0 comments

resolves #4

This PR removes h4 tags from the default TOC generation, as they were not added correctly.

Now, h3 is used by default and is filterable, allowing h4 tags to be added like so:

add_filter( 'toc_tags_for_toc', function( $tags) {
	return [ 'h3', 'h4' ];
}, 11 );

trepmal avatar May 25 '21 01:05 trepmal