Closed darrint closed 5 years ago
Ew!
The *
in front is not recognized as a valid 'pre-regex' character., which leads to the regex not being recognized at all. Which in turn removes everything after // in this line, because it's seen as a comment.
Parentheses around the regex.test()
would help here.
Sorry to say: this is just bad-styled code ;-)
I'll add +
, -
and *
as valid pre-chars. Let's hope it won't break anything else.
Thanks for the report.
I have the same issue, even the same piece of code is broken :) It's part of babel-polyfill
which is auto-generated and I can't easily modify it.
This has finally been fixed in Release 1.1.0.
The following code is handled incorrectly by rjsmin:
The result I get is:
Notice that a significant amount of code between "Safari" and "padEnd" is deleted.