Ran a big codebase of markdown through the linter, and found an edge case that results in the parser crashing and unable to process the remainder of the files for linting. This happens both from the cli version and the vscode version (since it seems like the vscode one just uses this lib internally)
Output from linter is:
[1:27:05 PM] ERROR: Exception while linting with markdownlint-cli2:
TypeError: e[n].slice is not a function
example markdown that reproduces:
1. some text
:::note
inner text
:::
2. some more text
It appears to be related to a :::note style callout existing within an ordered list.
Some more versions that reproduce the crash:
- some text
:::note
inner text
:::
- some more text
Ran a big codebase of markdown through the linter, and found an edge case that results in the parser crashing and unable to process the remainder of the files for linting. This happens both from the cli version and the vscode version (since it seems like the vscode one just uses this lib internally)
Output from linter is:
example markdown that reproduces:
It appears to be related to a
:::note
style callout existing within an ordered list.Some more versions that reproduce the crash: