fletcher / peg-multimarkdown

An implementation of MultiMarkdown in C, using a PEG grammar - a fork of jgm's peg-markdown. No longer under active development - see MMD 5.
Other
523 stars 55 forks source link

Use real character instead of entity for converted typographical punctuation. #86

Closed elmimmo closed 13 years ago

elmimmo commented 13 years ago

I have a deep dislike of entities of any kind, be them HTML, hex, unicode or whatever: with UTF-8 encoding being declared either with a meta tag or in the XML declaration (and nowadays why would anyone not), entities (all but ampersand and less than) become superfluous and serve exclusively to hinder HTML code readability and editability.

MultiMarkdown seems to use Unicode entities for some autoconverted typographical punctuation, at least for em/en dashes and single/double quotes. Note that it does respect real characters if they are entered manually in the Markdown file, so it is not like it is protecting the text content from being mangled if a meta tag declares an inappropriate encoding (or none at all for that matter; which at any rate should not be MMD's role to fix but the author using that wrong meta).

Please, if anything add an option to convert to the real characters instead of the entities.

fletcher commented 13 years ago

You can always convert the entities to Unicode characters as needed. MMD's entity handling was designed for compatibility with Smarty Pants, and to allow compatibility with ASCII.

Perhaps one day, but not a high priority for including in MMD itself right now.