svivian / q2a-markdown-editor

Markdown editor plugin for Question2Answer
55 stars 24 forks source link

Update to last Parsedown #16

Closed costasdroid closed 7 years ago

costasdroid commented 9 years ago

I could not resolve some issues like midword underscore (as f(x_1)+f(x_2)) for equations. Tested the latest Parsedown markdown parser and worked like a charm.

svivian commented 9 years ago

Cool, that seems like a good alternative to the old parser. Will take a closer look when I can and merge.

Do you know how well it complies to the CommonMark spec? Also do you know what is the best modern version of the Pagedown (JavaScript) component?

costasdroid commented 9 years ago

According to their readme and their tests, is somewhat 57% compilant:

"It passes most of the CommonMark tests. Most of the tests that don't pass deal with cases that are quite uncommon. Still, as CommonMark matures, compliance should improve."

The funny thing is that the js code worked like a charm in the preview window. They have different regExp pattern!

Maybe an option in admin panel for preffered parser (as default the pagedown)?

costasdroid commented 9 years ago

Is there any intention to drop down the php markdown and instead get the plain text entry and parse it only with the js?

Here is a convenient comparison between markdown parsers.

Babelmark

I found an unwanted transform in parsedown regarding maths so I will keep on searching for the "best" parser