executablebooks / mdformat

CommonMark compliant Markdown formatter
https://mdformat.rtfd.io
MIT License
439 stars 46 forks source link

mdformat adds "\" to squared brackets on footnotes. #382

Closed AnatolyBuga closed 1 year ago

AnatolyBuga commented 1 year ago

Describe the bug

mdformat adds "\" to squared brackets on footnotes.

Reproduce the bug

This:

Reference here[^1]

[^1] footnore

Gets converted into:

Reference here\[^1\]

\[^1\] footnore

Which is not displayed as a correct footnote.

List your environment

No response

welcome[bot] commented 1 year ago

Thanks for opening your first issue here! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! :tada:

vastbluesky commented 1 year ago

By default, mdformat only supports CommonMark syntax, which does not include footnotes. To use mdformat with footnotes, install the mdformat-footnote plugin.

AnatolyBuga commented 1 year ago

Got it, thanks.