Closed sionide21 closed 4 years ago
Great work thank you, I will merge this as soon as 1.5 is under dev
What is the meta
map in each AST node for? Should I be putting the fact that this is a wikilink there instead of seeing a class name?
Hmm, actually this might be a good idea, because it would allow to reverse the code.
But great you talked about this because I actually do not like the {"class", "wikilink"}
in the attributes array. I feel that the renderer should do such things... (I should have looked better, but anyway no big deal)
Let me give you some background information:
Right now we have only two defined entries verbatim: true
in case we parsed html and comment: true
in case we parsed html comments. However, I am considering to follow the request to put the raw html into the meta map in case of html, not sure how to do it though, probably option based and maybe only for the outermost node.
Eventually the decision is yours, if you want to add wikilink: true
to the map I am fine with it.
Concerning the class name, any particular reason why you put it there, maybe I'll leave it in there but I prefer the metadata approach.
I agree it makes more sense in the metadata. I'll make the change.
Great waiting for 1.5 now!
(Migrated from https://github.com/pragdave/earmark/pull/377)
This is commonly used in markdown based wikis (for example, Github's wiki).