From b276f9dc1f6acacc945c0d0c345640bed692c423 Mon Sep 17 00:00:00 2001 From: Raoul Gaillard Date: Sun, 27 Sep 2020 16:05:15 +0200 Subject: [PATCH] chore(tsconfig): Update target from esnext to es5 We shouldn't transpile client ts code to esnext because very few browsers support all features of es2020 right now. es5 seems to be a the right fit between ts default (es3) and today's browser support. For example with esnext as a target, optionnal chaining is not transpiled. --- packages/typescript/dom.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/typescript/dom.json b/packages/typescript/dom.json index f54e2ba..f8a30a4 100644 --- a/packages/typescript/dom.json +++ b/packages/typescript/dom.json @@ -4,7 +4,7 @@ "module": "esnext", "lib": ["dom", "dom.iterable", "esnext"], "noEmit": true, - "target": "esnext", + "target": "es5", "paths": { "@/*": ["src/*"] }