Shortcode headings not showing in TOC

Yep, this isn’t fixed. I have the same issue with v0.55.6

Hi @nolafs, moved your post to a new thread.

Would you share your shortcode with us, that isn’t working as you expect.

1 Like

Here is the shortcode:

<section>
<div class="grid-x grid-padding-x grid-padding-y article-block">
    <div class="cell small-12">
            {{ .Inner }}
    </div>
</div>
</section>

Thanks. Also give an example of how you call it

Like this

{{% content-block %}}

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

#### Test header two

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

{{% /content-block %}}

Interesting. So when I run your code as-is, the generated html contains the literal markdown that was passed in.

When tweaking to shortcode to be {{ .Inner | markdownify }} then the markdown is converted into html, but the heading does not show in the ToC.

Unless someone else can see why not, I think this is worth opening a GitHub issue for. https://github.com/gohugoio/hugo/issues