From add90c5603b0a07d9c44f5ece3c6008e040b610d Mon Sep 17 00:00:00 2001 From: coolxitech Date: Mon, 15 Dec 2025 21:23:26 +0800 Subject: [PATCH] =?UTF-8?q?feat(tsconfig):=20=E5=90=AF=E7=94=A8=20JSON=20?= =?UTF-8?q?=E6=A8=A1=E5=9D=97=E8=A7=A3=E6=9E=90=E5=92=8C=20ES=20=E6=A8=A1?= =?UTF-8?q?=E5=9D=97=E4=BA=92=E6=93=8D=E4=BD=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 添加 resolveJsonModule 选项以支持导入 JSON 文件 - 启用 esModuleInterop 以改善 CommonJS 和 ES 模块之间的兼容性 - 设置 allowSyntheticDefaultImports 允许合成默认导入 --- tsconfig.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tsconfig.json b/tsconfig.json index 16971f8..1029d16 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -4,6 +4,9 @@ "compilerOptions": { "paths": { "@/*": ["./src/*"] - } + }, + "resolveJsonModule": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true } }