From 37813bec8fecc411afc35e2a4847f98fbb933184 Mon Sep 17 00:00:00 2001 From: Runyasak Chaengnaimuang Date: Tue, 16 Dec 2025 23:21:45 +0700 Subject: [PATCH] :blue_book: doc: update Nuxt integration with Bun runtime configuration --- docs/integrations/nuxt.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/integrations/nuxt.md b/docs/integrations/nuxt.md index 7f7da2fb..c8ac0444 100644 --- a/docs/integrations/nuxt.md +++ b/docs/integrations/nuxt.md @@ -31,10 +31,17 @@ bun add -d nuxt-elysia export default defineNuxtConfig({ modules: [ // [!code ++] 'nuxt-elysia' // [!code ++] - ] // [!code ++] + ], // [!code ++] + nitro: { // [!code ++] + preset: 'Bun' // [!code ++] + } // [!code ++] }) ``` +::: tip +The `nitro.preset: 'Bun'` configuration is required because Elysia runs on Bun runtime. This tells Nuxt's Nitro to use Bun as the server runtime instead of the default Node.js runtime. +::: + 3. Create `api.ts` in the project root: ```typescript [api.ts]