From 064cedabf83cc215f50cf68657c0cc56d109409f Mon Sep 17 00:00:00 2001 From: melvinchia3636 Date: Mon, 8 Jun 2026 20:32:57 +0800 Subject: [PATCH] refactor: move contract file outside src folder --- client/{src => }/contract.ts | 0 client/src/forgeAPI.tsx | 2 +- client/tsconfig.json | 27 +++++++++++++++++++++------ 3 files changed, 22 insertions(+), 7 deletions(-) rename client/{src => }/contract.ts (100%) diff --git a/client/src/contract.ts b/client/contract.ts similarity index 100% rename from client/src/contract.ts rename to client/contract.ts diff --git a/client/src/forgeAPI.tsx b/client/src/forgeAPI.tsx index 210649f8f..5887c13f5 100644 --- a/client/src/forgeAPI.tsx +++ b/client/src/forgeAPI.tsx @@ -1,6 +1,6 @@ import { createForgeProxy, globalProxyRegistry } from '@lifeforge/shared' -import contract from './contract' +import contract from '../contract' globalProxyRegistry.set(contract, { moduleId: '', diff --git a/client/tsconfig.json b/client/tsconfig.json index 17db4b3cb..78a782ef1 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -2,10 +2,17 @@ "compilerOptions": { "target": "ES2020", "useDefineForClassFields": true, - "lib": ["ES2020", "DOM", "DOM.Iterable", "ES2024.Object"], + "lib": [ + "ES2020", + "DOM", + "DOM.Iterable", + "ES2024.Object" + ], "module": "ESNext", "skipLibCheck": true, - "types": ["node"], + "types": [ + "node" + ], /* Bundler mode */ "outDir": "${configDir}/tsbuild", "moduleResolution": "bundler", @@ -22,9 +29,17 @@ "rootDir": "../", "baseUrl": "./", "paths": { - "@/*": ["./src/*"], - "@core/*": ["../core/*"] + "@/*": [ + "./src/*" + ], + "@core/*": [ + "../core/*" + ] } }, - "include": ["./src/**/*", "./vite.config.ts"] -} + "include": [ + "./src/**/*", + "./vite.config.ts", + "./contract.ts" + ] +} \ No newline at end of file