Closed
Description
Initial checklist
- I read the support docs
- I read the contributing guide
- I agree to follow the code of conduct
- I searched issues and couldn’t find anything (or linked relevant results below)
Affected packages and versions
2.0.0
Link to runnable example
No response
Steps to reproduce
- Install & import
remark-heading-id
- in MDX remarkPlugins, add remark-heading-id
- Try to parse MDX:
## foo {#heading}
Expected behavior
The plugin handles the {#...}
extended markup syntax, and MDX parses the document normally
Actual behavior
Get error: Could not parse expression with acorn: Unexpected character '#'
It makes sense that MDX thinks that {...}
syntax is inline JS, but I would have thought plugins can be used to support heading ID Markdown extended syntax.
Runtime
Node v16
Package manager
npm v8
OS
Windows
Build and bundle tools
No response