Skip to content

Instantly share code, notes, and snippets.

@redradist
Created September 12, 2021 12:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save redradist/15f03dfb1d17ae974b7123fe3950bed2 to your computer and use it in GitHub Desktop.
Save redradist/15f03dfb1d17ae974b7123fe3950bed2 to your computer and use it in GitHub Desktop.
Babel SafeScript Transformer test script
const str0 = "3124122";
const num0 = 9;
const str1 = "3124122";
const num1 = str1 - num0;
const num2 = 55 + num1;
const num3 = 5 + num0;
const num4 = (num3 + 1) + 8;
let num5 = 3;
num5 += "3";
let str2 = "24256";
let numstr2 = +str2;
++numstr2;
function something(num) {
if (typeof num === "number") {
return num + 88;
}
return num + 88;
}
something(2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment