From 2daa8505d2c7519be688a88f8634b7830de0068e Mon Sep 17 00:00:00 2001 From: Christian Kogler Date: Tue, 28 Apr 2026 15:00:33 +0200 Subject: [PATCH] Fix: TypeScript 6 defaults module to "esnext" This causes some imports to fail (see https://github.com/codingcommons/typesafe-i18n/issues/789). The fix sets the module option to use CommonJS (which was used implicitly before anyway). --- packages/generator/src/parse-language-file.mts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/generator/src/parse-language-file.mts b/packages/generator/src/parse-language-file.mts index 06f08fe3..da24c8b3 100644 --- a/packages/generator/src/parse-language-file.mts +++ b/packages/generator/src/parse-language-file.mts @@ -89,6 +89,7 @@ const transpileTypescriptFiles = async ( skipLibCheck: true, sourceMap: false, noLib: true, + module: ts.ModuleKind.CommonJS, }) program.emit()