Open penn5 opened 10 months ago
This is also true when trying to insert characters by their code.
RS="\x1e";
becomes RS=`\\x1e`;
which then treats it as a literal string and no longer as a character code. I've had to use RS=String.fromCharCode(30);
to stop it doing that.
This is a problem with single-quoted strings as well. input.split('\n')
becomes input.split(`\\n`)
, which is wrong. In this case, I was able to use a regExp instead, like this: input.split(/\n/g)
, which works.
The code
alert("hello \"john\"");
, when minified, becomesalert(`hello \\"john\\"`)
.This is incorrect and results in two extra backslashes being introduced in the alert.
Tested in v0.5.6 because v0.6.0 has no prebuilt release (dead link in readme)