Skip to content

markdown conversion looses dash when there's two subsequent ones #73

@martinklepsch

Description

@martinklepsch

This

echo "[how to deal with promises](https://gist.github.com/roman01la/b939e4f2341fc2f931e34a941aba4e15#repl--asynchrony)" > bootleg-md-dash-omit.md
bootleg -e '(markdown "bootleg-md-dash-omit.md")'

breaks the link by omitting one of the dashes

<p><a href="https://gist.github.com/roman01la/b939e4f2341fc2f931e34a941aba4e15#repl–asynchrony">how to deal with promises</a></p>

This occurs regardless of whether the dashes are in the #anchor portion of the URL or the path itself.

Interestingly using markdown-clj I get a different result (v.1.10.0 as in project.clj):

(require '[markdown.core :as md])
(md/md-to-html-string "[how to deal with promises](https://gist.github.com/roman01la/b939e4f2341fc2f931e34a941aba4e15#repl--asynchrony)")
<p><a href='https://gist.github.com/roman01la/b939e4f2341fc2f931e34a941aba4e15#repl&ndash;asynchrony'>how to deal with promises</a></p>

cc @yogthos

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions