From aea2d9bea29e6d2bf0ae3b885ae8954433363cc6 Mon Sep 17 00:00:00 2001 From: Arthur DANJOU Date: Wed, 17 Dec 2025 09:35:16 +0100 Subject: [PATCH] =?UTF-8?q?feat:=20mettre=20=C3=A0=20jour=20la=20configura?= =?UTF-8?q?tion=20de=20Nuxt=20et=20am=C3=A9liorer=20les=20types=20dans=20l?= =?UTF-8?q?a=20configuration=20du=20worker?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nuxt.config.ts | 23 ++++++++--------------- worker-configuration.d.ts | 17 +++++++++++++---- 2 files changed, 21 insertions(+), 19 deletions(-) diff --git a/nuxt.config.ts b/nuxt.config.ts index 32b9b4b..0db262d 100644 --- a/nuxt.config.ts +++ b/nuxt.config.ts @@ -1,5 +1,4 @@ export default defineNuxtConfig({ - compatibilityDate: '2025-12-13', modules: [ '@nuxthub/core', @@ -10,18 +9,11 @@ export default defineNuxtConfig({ '@nuxt/ui' ], - css: ['~/assets/css/main.css'], - devtools: { - enabled: true, + enabled: true }, - content: { - database: { - type: 'd1', - bindingName: 'artapi' - } - }, + css: ['~/assets/css/main.css'], runtimeConfig: { discord: { @@ -42,10 +34,15 @@ export default defineNuxtConfig({ experimental: { asyncContext: true }, + compatibilityDate: '2025-12-13', + + nitro: { + preset: 'cloudflare_module' + }, hub: { cache: true, - db: 'sqlite', + db: 'sqlite' }, eslint: { @@ -57,10 +54,6 @@ export default defineNuxtConfig({ } }, - nitro: { - preset: "cloudflare_module", - }, - mcp: { name: 'ArtMCP', version: '1.0.0', diff --git a/worker-configuration.d.ts b/worker-configuration.d.ts index 7f1c6d8..0eb85bd 100644 --- a/worker-configuration.d.ts +++ b/worker-configuration.d.ts @@ -1,7 +1,10 @@ /* eslint-disable */ -// Generated by Wrangler by running `wrangler types` (hash: 4ffc2e39cf9c8dc235ec80f2b29fba21) -// Runtime types generated with workerd@1.20251213.0 2025-12-13 +// Generated by Wrangler by running `wrangler types` (hash: 0e830e66d194b5321c2ceb2f6b8949ed) +// Runtime types generated with workerd@1.20251213.0 2025-12-13 nodejs_compat declare namespace Cloudflare { + interface GlobalProps { + mainModule: typeof import("./.output/server/index"); + } interface Env { CACHE: KVNamespace; NUXT_DISCORD_ID: string; @@ -20,6 +23,12 @@ declare namespace Cloudflare { } } interface Env extends Cloudflare.Env {} +type StringifyValues> = { + [Binding in keyof EnvType]: EnvType[Binding] extends string ? EnvType[Binding] : string; +}; +declare namespace NodeJS { + interface ProcessEnv extends StringifyValues> {} +} // Begin runtime types /*! ***************************************************************************** @@ -8601,7 +8610,7 @@ type AIGatewayHeaders = { [key: string]: string | number | boolean | object; }; type AIGatewayUniversalRequest = { - provider: AIGatewayProviders | string; + provider: AIGatewayProviders | string; // eslint-disable-line endpoint: string; headers: Partial; query: unknown; @@ -8617,7 +8626,7 @@ declare abstract class AiGateway { gateway?: UniversalGatewayOptions; extraHeaders?: object; }): Promise; - getUrl(provider?: AIGatewayProviders | string): Promise; + getUrl(provider?: AIGatewayProviders | string): Promise; // eslint-disable-line } interface AutoRAGInternalError extends Error { }