Closed Tc-001 closed 2 years ago
Just a little update here as well: I've fixed this, we just need to wait for @natemoo-re to find a way to add my fix to Astro. :)
It's a bit more complicated than usual because the fix needs to be applied to the tokenizer of an upstream package (micromark-extension-mdx-jsx
). As the special shorthand syntax isn't specs-compliant, the upstream author is unlikely to include it in their package, so we will need to fork it or bring the code in in some other way.
What version of
astro
are you using?1.0.0-beta.35
Are you using an SSR adapter? If so, which one?
none
What package manager are you using?
npm, pnpm
What operating system are you using?
Linux
Describe the Bug
(Fork from #3458 )
Having a markdown file with the character
:
be parsed will result in a error in both dev and build.test.md
with<div :width="1+1" />
import {Content} from "./test.md"
<Content />
(may be optional, just having it imported could be enough)Produces an error:
In my site I also got:
Removing the
:
character fixes the error in both cases.Bug got introduced in #3410
Link to Minimal Reproducible Example
https://stackblitz.com/edit/github-majhwx?file=src/pages/index.astro
Participation