Open blue148 opened 2 years ago
Same Issue, I started getting it when I updated to mdxv2
I also have the same issue, after updating to gatsby-plugin-mdx v4 and mdxv2.
Same here
has anyone found any workarounds?
I had to build my own. Just made a custom component that I add in the markdown<TableOfContents tableOfContents={props.data.mdx.tableOfContents} />
and then I loop over the tableOfContents.items
inside that component.
@signalwerk any thoughts on whether this is a bug or oils be addressed? Seems like basically mdx2 is not supported with the current version due to this...
Having the same issue sadly.
I couldn't figure out how to fix the tests, but I published @ricale's patch as a new npm package to use in the meantime.
https://www.npmjs.com/package/gatsby-remark-table-of-contents-patch
After installing the plugin and setting up the config, the output of the MDX file into HTML is "printing" the wrapping div tag as a string instead of rendering it as an HTML tag
gatsby-config.js
MDX sample file
Typography Usage
Typography Fonts
Typography Sizes
Accessibility Considerations with Type
Typography
<div className="table-of-contents">Typography Usage
Typography Fonts
Typography Sizes
Accessibility Considerations with Type