yoshuawuyts / vmd

:pray: preview markdown files
MIT License
1.18k stars 111 forks source link

Links to ids doesn't work when using letters from foreign languages like Ż #116

Open stpoa opened 6 years ago

stpoa commented 6 years ago

Below doesn't work in vmd.

[Header with Ż link](#header-with-ż)
# Header with Ż

Without foreign characters works as expected:

[Header with Z link](#header-with-z)
# Header with Z
maxkueng commented 6 years ago

Interesting find. This work on GitHub if you use the same casing ([Header with Ż link](#header-with-Ż) instead of [Header with Ż link](#header-with-ż)).
However, this doesn't make it work in vmd.

The reason seems to be that the library that converts the MDAST to HTML escapes the character in the URL.

MDAST Node: image

HTML: image

This probably needs to be fixed in one of the remark or rehype libaries.