- This topic has 16 replies, 6 voices, and was last updated 3 years, 6 months ago by
David.
-
AuthorPosts
-
August 1, 2021 at 3:40 am #1879086
Leonard
Hi,
Is there any block or any ways I can create a Table of Content for my article?
I tried to look around the blocks but I cant see any obvious one.
I’m not proficient and is still a new user.
Thank you!
August 1, 2021 at 6:35 am #1879202David
StaffCustomer SupportHi there,
its not block based, but this plugin will add a Table of Contents to your Posts:
August 3, 2021 at 7:05 am #1882055Leonard
ok thank you!
August 3, 2021 at 8:13 am #1882366David
StaffCustomer SupportYou’re welcome
December 9, 2021 at 4:01 am #2043410Tobias
It would be great if I could create a table of content block in Elements, so that it can be reused on every blog post automatically. Just like the Page Hero. Is there not a way to insert the h2’s and h3’s as dynamic content in a block? Shouldn’t this be something we could arrange with dynamic content?
It would be handy for style consistency, content management and for reducing separate plugins.
December 9, 2021 at 6:50 am #2043541David
StaffCustomer SupportHi there,
ToC plugins ‘scrape’ the_content to find all the Headings, store them in array for later display as bunch of links, and then filter the post content to inject the relevant HTML Anchors for each of the heading links. A lot of this relies on filter hooks and/or Javascript to do this. And theres a lot of things to consider here such as Accessibility.
All of which is completely outside of what Block Elements Dynamic Data does. It ‘simply’ allows you to retrieve data from your database, such as a Post Term or the entire Post Content.
It may be something we look at in the future for GenerateBlocks but for now a ToC plugin is the way to go.
December 31, 2021 at 12:41 am #2064569Andrea
Thanks David, I was also wondering if it was possible to add a dynamically generated table of content without using an extra plugin. Thanks
Andrea
December 31, 2021 at 6:52 am #2064767David
StaffCustomer SupportGlad to be of help.
Its definitely plugin requirement today 🙂January 2, 2022 at 10:41 pm #2067016Andrea
Yes, I understand, thanks. I’ve got my devs to do some coding, and we’ll see if we can sort it out. Cheers
Andrea
October 12, 2022 at 7:51 pm #2371770Wendy
It’s a shame there isn’t a block, like with Kadence. I don’t want to add another plugin to my site.
October 13, 2022 at 1:36 am #2372007David
StaffCustomer SupportHi there,
personally i see this kind of thing as a dedicated plugin requirement.
Having a specific plugin for just the ToC will probably result in a much lighter and more flexible result then those bundled into a block plugin. Just my 2 cents 🙂October 26, 2022 at 5:11 am #2387463George
Like Wendy and others have said, I also believe this will be nice to have it as a Gutenberg Block without external plugins.
David, can you please explain why the Easy Table of Contents can be a better option in simple words?
October 26, 2022 at 6:11 am #2387567David
StaffCustomer SupportUsing a dedicated plugin for niche features like a TOC, ( generally ) means you have a developer who is 100% focused on delivering the best product. Both in terms of support and feature improvements as they are focused on just that one feature.
When you have a plugin ( or worst still a Theme ) that bundles lots of features, you don’t have the same level of focus. This may result in sub-par features. It most definitely means a lot more code. Code that has to be maintained and supported. And code that is obsolete for any site that doesn’t require that feature.
October 26, 2022 at 6:34 am #2387622Andrea
Thanks, David. I implemented it by code
October 26, 2022 at 7:07 am #2387696David
StaffCustomer SupportGlad to hear that Andrea!
-
AuthorPosts
- You must be logged in to reply to this topic.