Skip to content

Conversation

@chris-canipe
Copy link

The RE_COMMENT regex seems unnecessarily complex: I've simplified it.

The whitespace normalization is the focus of this pull request. I'm working with Rails' asset pipeline and I found a peculiarity where one of its resulting CSS assets contains over 5,000 spaces (between two sheets that it pulled together). This is causing selectivizr to hang; I suspect the excessive space may be triggering "catastrophic backtracking." I've wrapped the loaded stylesheet with normalizeWhitespace to prevent this from happening.

@corysimmons
Copy link

@keithclark disappeared so I'm going to try and maintain this project at https://github.com/corysimmons/selectivizr2

Would you please reopen/rebase your PR over there?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants