substitute marked.js markdown parser taken from https://github.com/chjj/marked/blob/master/lib/marked.js