earldouglas/codedown

[[ in output when Markdown contains task list items

Closed this issue · 3 comments

Task list items is an extension of GitHub Flavored Markdown. It looks like this:

* [X] checked
* [ ] unchecked

```lang
code
```

If a Markdown document containing a task list is given to codedown, the output incorrectly contains [ characters.

const codedown = require("codedown");
const lines = [
    "* [X] checked",
    "* [ ] unchecked",
    "",
    "```lang",
    "code",
    "```",
];
const input = lines.join("\n");
console.log(codedown(input, "lang"));

Expected output: code
Actual output: [[code

@yoursunny Are you still running into this with the latest version of codedown?

I added a test in #18 that passes, so I think it might have been fixed by some other change.

I believe this bug has been resolved in codedown 2.1.7.

Thanks, and apologies for the delayed response to this issue!