-
Notifications
You must be signed in to change notification settings - Fork 889
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Escape potential ol triggers" bug #181
Comments
Thanks for this. It will hopefully be fixed in a future version |
The turndown branch fixed it. But I can't tell how it did it. Could you explain it here. In the master branch, I had to comment out the following line in index.js to fix it. // Escape potential ol triggers
input = input.replace(/(\d+)\. /g, '$1\\. ') // line 203 |
The current version is a little naive in it's approach to escaping potential ordered list ( The turndown branch takes a different approach. Rather than searching the whole input, it escapes every text node as it walks the DOM tree. This allows the escape method to be far more accurate about how it finds and replaces potential Hope that helps. |
Thank you for the explanation! |
This will be fixed in turndown v4 |
expected results is
not
The text was updated successfully, but these errors were encountered: