mdx-util icon indicating copy to clipboard operation
mdx-util copied to clipboard

Transcluding other MDX using mdx.macro crashes the page

Open olivvybee opened this issue 6 years ago • 1 comments

Using mdx.macro, if I have the following two files:

transcluded.mdx

This is some **markdown** content.

main.mdx

import Transcluded from '../../../src/transcluded.mdx';

<Transcluded />

then I get the following warning and error in the console, and the page crashes.

Warning: </static/media/Transcluded.312f719b.mdx /> is using incorrect casing. Use PascalCase for React components, or lowercase for HTML elements.
    in /static/media/Transcluded.312f719b.mdx (at Main.mdx:18)
react-dom.development.js:7935 Uncaught (in promise) DOMException: Failed to execute 'createElement' on 'Document': The tag name provided ('/static/media/Transcluded.312f719b.mdx') is not a valid name.

olivvybee avatar Feb 07 '19 12:02 olivvybee

So I came here after asking from and being referred to come back here: https://github.com/mdx-js/mdx/discussions/1328

How can we possibly fix this? If someone could point me in the right direction, I might probably be able to help.

dorelljames avatar Nov 12 '20 10:11 dorelljames