From 86ea83a59d7220c8e8d6b35e24505aaff1141cc4 Mon Sep 17 00:00:00 2001 From: Andrew Bradley Date: Sun, 31 Oct 2021 21:38:38 -0400 Subject: [PATCH 1/2] add swc target es2022 --- src/transpilers/swc.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/transpilers/swc.ts b/src/transpilers/swc.ts index 6955bc90e..1d6961ed6 100644 --- a/src/transpilers/swc.ts +++ b/src/transpilers/swc.ts @@ -143,7 +143,7 @@ targetMapping.set(/* ts.ScriptTarget.ES2018 */ 5, 'es2018'); targetMapping.set(/* ts.ScriptTarget.ES2019 */ 6, 'es2019'); targetMapping.set(/* ts.ScriptTarget.ES2020 */ 7, 'es2020'); targetMapping.set(/* ts.ScriptTarget.ES2021 */ 8, 'es2021'); -targetMapping.set(/* ts.ScriptTarget.ESNext */ 99, 'es2021'); +targetMapping.set(/* ts.ScriptTarget.ESNext */ 99, 'es2022'); type SwcTarget = typeof swcTargets[number]; /** @@ -160,6 +160,7 @@ const swcTargets = [ 'es2019', 'es2020', 'es2021', + 'es2022' ] as const; const ModuleKind = { From 53731e6d6e144365c06e7fd60bc54a934cd753b7 Mon Sep 17 00:00:00 2001 From: Andrew Bradley Date: Sun, 31 Oct 2021 21:47:28 -0400 Subject: [PATCH 2/2] lint fix; --- src/transpilers/swc.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/transpilers/swc.ts b/src/transpilers/swc.ts index 1d6961ed6..a5ba44265 100644 --- a/src/transpilers/swc.ts +++ b/src/transpilers/swc.ts @@ -160,7 +160,7 @@ const swcTargets = [ 'es2019', 'es2020', 'es2021', - 'es2022' + 'es2022', ] as const; const ModuleKind = {