From 1ca0860c31503453f3a137a13ed913703e4aca3d Mon Sep 17 00:00:00 2001 From: Evan Wallace Date: Tue, 1 Sep 2020 13:17:40 -0700 Subject: [PATCH] target es5 for uglify tests (#356) --- scripts/uglify-tests.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/scripts/uglify-tests.js b/scripts/uglify-tests.js index 9e92f2a87c0..3a4a7a3ab0c 100644 --- a/scripts/uglify-tests.js +++ b/scripts/uglify-tests.js @@ -102,10 +102,8 @@ async function test_case(service, test) { // Run esbuild as a minifier try { var { js: output } = await service.transform(input_code, { - // Don't use "minifyWhitespace: true" because esbuild uses some ES6 syntax - // to make things shorter and uglify can't parse ES6. - minifySyntax: true, - minifyIdentifiers: true, + minify: true, + target: 'es5', }); } catch (e) { const formatError = ({ text, location }) => {