swc/node-swc/__tests__/transform/issues_test.mjs
강동윤 9793926cc8
fix(es/minifier): Fix bugs and implement more rules (#2032)
swc_ecma_minifier:
 - Fix an infinite loop. (#2028)
 - Don't remove span hygiene. (#2022)

swc_ecma_codegen:
 - Fix codegen of `return` with `async` arrow. (#2020)

swc:
 - Respect `minify = false`. (#2019)
2021-08-08 14:19:04 +00:00

16 lines
293 B
JavaScript

import swc from "../../..";
it("should respect jsc.minify = false", async () => {
const { code } = await swc.transform(`
const hello = () => {
console.log('hello');
};
`, {
jsc: {
},
minify: false,
});
expect(code).toContain("\n");
})