Skip to content
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

This regex may be stucked by input strings. #9731

Closed
2bdenny opened this issue Mar 8, 2018 · 1 comment
Closed

This regex may be stucked by input strings. #9731

2bdenny opened this issue Mar 8, 2018 · 1 comment
Assignees
Labels
confirmed We want to fix or implement it Project:JS Environment

Comments

@2bdenny
Copy link

2bdenny commented Mar 8, 2018

text = text.replace(/(\n\n[ ]{0,3}<!(--[^\r]*?--\s*)+>[ \t]*(?=\n{2,}))/g,hashElement);

We tested all regexes in the project and found this regex may be stucked by input strings like: \n\n<!--\n\n<!--------<\n\n<!------------------------------------->]Vx0\n\n\n------!!<\n\n\n\n]-----<!]Vx0\n\n-------<!

@hwillson
Copy link
Contributor

hwillson commented Mar 9, 2018

Thanks @2bdenny - this is known. We're currently considering deprecating this (and the showdown) package from core.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed We want to fix or implement it Project:JS Environment
Projects
None yet
Development

No branches or pull requests

2 participants