Replace unmaintained markdown parser library with a new one#78
Conversation
williamdes
left a comment
There was a problem hiding this comment.
Thank you so much, you can go ahead with the tests
I doubt we will have much complaints
2963aad to
f9361ce
Compare
|
Done. As noted in the PR description the 6 remaining unit failures fail without this PR so I haven't touched those. |
williamdes
left a comment
There was a problem hiding this comment.
Thanks, I will update the other unhappy tests
the link transform was useful, I may write some code to save it
|
I am waiting on parsedown/parsedown#7 before updating the phar. Will keep you updated, if this goes nowhere I will go back to your solution 🙏🏻 |
|
Seems to work, new fork helped me. |
|
Symfony v8 support added, -dev phar released. Testing time ! |
Replaces
erusev/parsedownwithleague/commonmarkThe following 6 unit tests were failing prior to this change:
The remaining failures all look benign - the new package deals with HTML and whitespace differently than the old one. Specifically it doesn't trim whitespace, and it seems to adhere to the HTML5 spec and massages malformed HTML into valid HTML.
I've left the failing tests as they are so that you can see for yourself what the differences are. If you're happy with the changes let me know and I'll fix up the tests that are failing as a result of this change (i.e not the above 6).
Note that there are some configuration options for
league/commonmark, but none of them include "don't fix broken HTML" or "trim whitespace" so using this library we won't get identical results to the previous one without significant effort.