From a8f4cfbeaec294d362abdfcca7a4d748bec142b9 Mon Sep 17 00:00:00 2001 From: npmrun <1549469775@qq.com> Date: Thu, 16 Apr 2026 21:57:13 +0800 Subject: [PATCH] feat: add bun-types support in TypeScript configuration Enhance TypeScript configuration in nuxt.config.ts to include 'bun-types' in both the main and nitro sections. Update package.json to add 'bun-types' as a dependency. --- nuxt.config.ts | 8 ++++++++ package.json | 1 + 2 files changed, 9 insertions(+) diff --git a/nuxt.config.ts b/nuxt.config.ts index 059a4d5..375bfc6 100644 --- a/nuxt.config.ts +++ b/nuxt.config.ts @@ -7,10 +7,18 @@ export default defineNuxtConfig({ fonts: false }, devtools: { enabled: true }, + typescript: { + tsConfig: { + compilerOptions: { + types: ['bun-types'], + } + } + }, nitro: { typescript: { tsConfig: { compilerOptions: { + types: ['bun-types'], resolvePackageJsonExports: true, resolvePackageJsonImports: true, baseUrl: './', diff --git a/package.json b/package.json index d6296a6..0fe5a49 100644 --- a/package.json +++ b/package.json @@ -43,6 +43,7 @@ "@types/better-sqlite3": "^7.6.13", "@types/multer": "2.1.0", "@types/pg": "8.20.0", + "bun-types": "^1.3.12", "drizzle-kit": "0.31.10", "tsx": "4.21.0", "typescript": "6.0.2"