-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Highlight Auto breaking on multiple periods #1505
Comments
Thanks for reporting this! Our parser is indeed susceptible to such things if not handled carefully. Fixed. |
@isagalaev No problem thanks for the quick fix! 👍 |
Also, until the next version of highlight.js is released you can either build yourself a copy from master or explicitly list all the language you need for auto highlighting, so the offending language ("gams") is not included. |
@isagalaev Are you planing to release the next version soon? Or maybe some alfa version? This fix is very important to us at Rocket.Chat and we don't want to release a new NPM package just to get this fix in our next version. Can we help you in some way? Thanks |
Our upcoming release date is Tuesday May, 30 (we do it every 6 weeks). In the meantime you can always build a custom version for yourself from master: http://highlightjs.readthedocs.io/en/latest/building-testing.html |
Running across an odd issue.
If we do:
highlightjs.highlightAuto('I ..');
the browser tab completely locks up. We're on the latest version of highlightjs 9.11.0https://runkit.com/590140aeafa0170012b6169c/590141941ce99600127a433b
A single period seems to work fine. But multiple breaks and if no space before it it also works fine.
Also oddly seems to be a single char space and then multiple periods. If you do multiple letters first its a no go.
<letter>+<space>+..
The text was updated successfully, but these errors were encountered: