enhance imports (#5287)

This commit is contained in:
Alex Lam S.L
2022-01-12 08:24:04 +00:00
committed by GitHub
parent f639a30bd2
commit 9a58270b70
2 changed files with 17 additions and 0 deletions

View File

@@ -106,6 +106,22 @@ drop_unused: {
}
}
drop_side_effect_free: {
options = {
imports: true,
side_effects: true,
toplevel: true,
unused: true,
}
input: {
import foo from "bar";
var a = foo;
}
expect: {
import "bar";
}
}
mangle: {
rename = false
mangle = {