Pandoc (Markdown to HTML) converts some character entities to UTF-8 #844
Comments
Pandoc converts all entities to unicode characters. That is because it needs to handle output formats other than HTML. If you use the Another option is to use the |
Thanks a lot! |
troglobit
added a commit
to troglobit/resume
that referenced
this issue
Aug 30, 2016
The generated HTML output from pandoc generated unicode characters, which did not display correctly in Firefox. This patch adds a small workaround as suggested in jgm/pandoc#844 Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have a Markdown document containing the HTML character entity
→
. When I convert this to HTML usingpandoc -o myfile.html myfile.md
, the character is converted to a UTF-8 encoded right arrow character, which my browser displays as an ugly jumble→
. Other character entities like&
, on the other hand, are preserved correctly as inline HTML.A workaround to this is to include a tag
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
at the beginning of my Markdown document, but that seems a little inelegant as I can't assume that any Markdown converter will produce UTF-8 encoded output. IMHO, pandoc should either consequently preserve HTML character entites, or properly announce UTF-8 encoding in the HTML output.
I'm using pandoc on Windows:
The text was updated successfully, but these errors were encountered: