From e410847e74363f468f29c3024b3b8374ad642ff6 Mon Sep 17 00:00:00 2001 From: melchor629 Date: Sat, 17 Feb 2024 14:00:06 +0100 Subject: [PATCH] fix: build issue --- package-lock.json | 57 ++++++---------------- package.json | 3 +- packages/hny-scripts/config/vite.config.js | 2 +- 3 files changed, 19 insertions(+), 43 deletions(-) diff --git a/package-lock.json b/package-lock.json index c438dcc..88286fa 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,8 @@ ], "devDependencies": { "prettier": "^3.1.1", - "serve": "^14.0.1" + "serve": "^14.0.1", + "typescript": "^5.3.3" } }, "node_modules/@melchor629/hny-2018": { @@ -1170,6 +1171,19 @@ "node": ">=0.10.0" } }, + "node_modules/typescript": { + "version": "5.3.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", + "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", + "devOptional": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, "packages/2018": { "name": "@melchor629/hny-2018", "version": "1.0.0", @@ -6130,19 +6144,6 @@ "resolved": "https://registry.npmjs.org/ts-chacha20/-/ts-chacha20-1.2.0.tgz", "integrity": "sha512-PTyPoWYHc2we8P2NTn5hpYG211popWbkjiw+k63xqjeMrx9pPtXSclz9F3fu0Tpr+vfR1xxcQFwsEkh1cXMLqw==" }, - "packages/2023/node_modules/typescript": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", - "dev": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "packages/2023/node_modules/zustand": { "version": "4.4.7", "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.7.tgz", @@ -7234,19 +7235,6 @@ "resolved": "https://registry.npmjs.org/three/-/three-0.160.0.tgz", "integrity": "sha512-DLU8lc0zNIPkM7rH5/e1Ks1Z8tWCGRq6g8mPowdDJpw1CFBJMU7UoJjC6PefXW7z//SSl0b2+GCw14LB+uDhng==" }, - "packages/2024/node_modules/typescript": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", - "dev": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "packages/2024/node_modules/zustand": { "version": "4.4.7", "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.7.tgz", @@ -8179,7 +8167,7 @@ "fs-extra": "^11.1.0", "klaw": "^4.0.1", "sass": "^1.35.1", - "vite": "^5.0.10", + "vite": "^5.0.12", "vite-plugin-checker": "^0.6.2" }, "bin": { @@ -8705,19 +8693,6 @@ "node": ">=0.10.0" } }, - "packages/hny-scripts/node_modules/typescript": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", - "devOptional": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "packages/hny-scripts/node_modules/vite": { "version": "5.1.3", "resolved": "https://registry.npmjs.org/vite/-/vite-5.1.3.tgz", diff --git a/package.json b/package.json index 16bcd3c..110cc99 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ }, "devDependencies": { "prettier": "^3.1.1", - "serve": "^14.0.1" + "serve": "^14.0.1", + "typescript": "^5.3.3" } } diff --git a/packages/hny-scripts/config/vite.config.js b/packages/hny-scripts/config/vite.config.js index 56dd610..f85e435 100644 --- a/packages/hny-scripts/config/vite.config.js +++ b/packages/hny-scripts/config/vite.config.js @@ -7,7 +7,7 @@ const host = process.env.HOST || '0.0.0.0' const port = parseInt(process.env.PORT || '3000', 10) export default defineConfig({ - plugins: [react(), checker({ typescript: paths.useTypeScript })], + plugins: [react(), ...(paths.useTypeScript ? [checker({ typescript: true })] : [])], root: paths.projectPath, base: paths.publicPath, build: {