14ef0b4211
Looking at the *built* files you'll notice some lines containing nothing more than a semicolon. This is the result of (mostly top-level) `if`-statements, which include `PDFJSDev`-checks, that evalute to `false` during Babel parsing. This has always annoyed me a bit, and looking at Babel plugin it seems that we can fix this simply by *removing* the relevant nodes.
35 lines
282 B
JavaScript
35 lines
282 B
JavaScript
if ('test') {
|
|
"1";
|
|
}
|
|
if (true) {
|
|
"1";
|
|
}
|
|
if (true) {
|
|
"1";
|
|
} else {
|
|
"2";
|
|
}
|
|
if (false) {
|
|
"1";
|
|
}
|
|
if (false) {
|
|
"1";
|
|
} else {
|
|
"2";
|
|
}
|
|
if (true && false) {
|
|
"1";
|
|
}
|
|
if (true && false || '1') {
|
|
"1";
|
|
}
|
|
|
|
function f1() {
|
|
if (true) {
|
|
"1";
|
|
}
|
|
if (false) {
|
|
"2";
|
|
}
|
|
}
|