From 721e7b60815e3b47227f720e13326a1275b752e3 Mon Sep 17 00:00:00 2001 From: WJG Date: Sun, 2 Jun 2024 23:57:22 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BD=BF=E7=94=A8=E5=B5=8C=E5=85=A5?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/string.ts | 4 ++-- tsconfig.json | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/utils/string.ts b/src/utils/string.ts index 7725304..6685b26 100644 --- a/src/utils/string.ts +++ b/src/utils/string.ts @@ -1,6 +1,6 @@ -import { readJSONSync } from "./io"; +import { version } from "../../package.json"; -export const kVersion = readJSONSync("package.json").version; +export const kVersion = version; export const kAreYouOK = "¿ʞо ∩оʎ ǝɹɐ"; // are you ok? diff --git a/tsconfig.json b/tsconfig.json index 6c9d638..20963bd 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -6,7 +6,8 @@ "target": "esnext", "module": "esnext", "esModuleInterop": true, - "moduleResolution": "node" + "moduleResolution": "node", + "resolveJsonModule": true }, "include": ["src", "tests"], "exclude": ["node_modules", "dist"]