Im using markdown to store chord lyrics and it works great. https://codepen.io/rrob/pen/GxYgOP
Using * for a tag <em>for chords and position it using css.
But now I want it to be in the presentation, and the markdown parsing there is complicated. I am trying to insert a tag with str.replace , but I cannot close the tag.
text text *chord* text text
replaced by:
text text <em>chord<em> text text
and of course I need:
text text <em>chord</em> text text
Pls do you know some simple solution for parsing custom tags? Javascript / jQuery.
source
share