markit icon indicating copy to clipboard operation
markit copied to clipboard

Option to control escaping of HTML entites

Open rprieto opened this issue 11 years ago • 2 comments

I currently use markit for its parsing abilities, especially around custom rendering. However the target is not a web page, so ideally I wouldn't want any escaping of HTML entities.

What would you think of a new escape: false option to the global Markit options? I imagine it could short circuit the following function, which is called by both InlineLexer and Renderer.

function escape(html, escape, encode) { ... }

Thanks

rprieto avatar Dec 11 '13 12:12 rprieto

@rprieto How about put escape in the renderer? In this case, you can change the renderer.

lepture avatar Dec 11 '13 15:12 lepture

Thanks that sounds good. To make sure I don't break anything, could you explain really quickly why escape(...) is called by both InlineLexer and Renderer? Do you think it could all move to the rendering phase?

rprieto avatar Dec 11 '13 21:12 rprieto