\r\n\r\nself.addEventListener(\r\n 'message',\r\n (\r\n evt: MessageEvent\u003C{\r\n message: string\r\n }>,\r\n ) => {\r\n const { message } = evt.data\r\n const greeting = `Hello ${upperCase(message)} from assets!`\r\n\r\n postMessage({ greeting })\r\n },\r\n)\r\n```\r\n\r\nCreate a app.vue file\r\n\r\n```vue\r\n\u003Cscript setup lang=\"ts\">\r\nimport Runner from './utils/workers/index?worker'\r\n\r\nconst message = ref('Nuxt')\r\n\r\nfunction sayHello(from: 'workers' | 'composable') {\r\n if (from === 'workers') {\r\n const worker = new Runner()\r\n worker.postMessage({ message: message.value })\r\n worker.addEventListener(\r\n 'message',\r\n (\r\n evt: MessageEvent\u003C{\r\n greeting: string\r\n }>,\r\n ) => {\r\n const { greeting } = evt.data\r\n alert(greeting)\r\n },\r\n )\r\n } else {\r\n sayHelloFromComposable(message.value)\r\n }\r\n}\r\n\u003C/script>\r\n\r\n\u003Ctemplate>\r\n \u003Ch1>Demo with auto imports\u003C/h1>\r\n \u003CCustomInput v-model=\"message\" />\r\n \u003Cbutton type=\"submit\" @click=\"sayHello('composable')\">\r\n Hello from composable\r\n \u003C/button>\r\n \u003Cbutton type=\"submit\" @click=\"sayHello('workers')\">Hello from workers\u003C/button>\r\n\u003C/template>\r\n./assets/workers\r\n```\r\n\r\n### Describe the bug\r\n\r\n## Actual Behavior\r\n\r\nIn development mode, the utils/ directory is auto imported, so the upperCase function is available on the assets/index.ts file.\r\n\r\nIn production mode, we have this error:\r\n\r\n```txt\r\nUncaught ReferenceError: upperCase is not defined\r\n at index-8e797b43.js:1:88\r\n```\r\n\r\n## Expected Behavior\r\n\r\nThis should work with the same behavior in development and production mode.\r\n\r\n\r\n### Additional context\r\n\r\n\r\nI call the utils to function in `worker` file\r\n\r\n### Logs\r\n\r\n_No response_",[3032,3035,3038,3041],{"name":3033,"color":3034},"workaround available","11376d",{"name":3036,"color":3037},"bug","d73a4a",{"name":3039,"color":3040},"vite","3574D1",{"name":3042,"color":3043},"🍰 p2-nice-to-have","0E8A16",24590,"Utils folder is not auto imported on production mode when using in worker file","2024-11-19T11:52:00Z","https://github.com/nuxt/nuxt/issues/24590",0.7217487,{"description":3050,"labels":3051,"number":3053,"owner":3023,"repository":3054,"state":3024,"title":3055,"updated_at":3056,"url":3057,"score":3058},"### Environment\r\n\r\n```\r\n------------------------------\r\n- Operating System: Darwin\r\n- Node Version: v21.6.1\r\n- Nuxt Version: 3.11.0\r\n- CLI Version: 3.10.1\r\n- Nitro Version: 2.9.4\r\n- Package Manager: bun@1.0.29\r\n- Builder: -\r\n- User Config: -\r\n- Runtime Modules: -\r\n- Build Modules: -\r\n------------------------------\r\n```\r\n\r\n### Reproduction\r\n\r\nhttps://stackblitz.com/edit/github-krtpdn?file=test%2Fsomething.spec.ts\r\n\r\n### Describe the bug\r\n\r\nUsing `console.log()` within an e2e test doesnt output the test in stdout as well as in devtools \"Console\" tab. Only seems to work for beforeAll().\r\n\r\nTry:\r\n\r\n1. `bun run test`\r\n-> No logs in console\r\n\u003Cimg width=\"864\" alt=\"Bildschirmfoto 2024-03-19 um 16 15 57\" src=\"https://github.com/nuxt/nuxt/assets/5103210/74fafc99-45bf-4499-bdc0-151a90ff41b0\">\r\n\r\n2. ```bun run dev```, then open devtools -> Vitest\r\n> No logs in tab \"Console\"\r\n\r\n\u003Cimg width=\"420\" alt=\"Bildschirmfoto 2024-03-19 um 16 13 11\" src=\"https://github.com/nuxt/nuxt/assets/5103210/28aeb6de-832f-4b1e-bbc7-b101f7e4c56f\">\r\n\r\n### Logs\r\n\r\n_No response_",[3052],{"name":3036,"color":3037},795,"test-utils","e2e tests dont show any console logs in stdout and in vitest/ui","2025-03-13T08:34:24Z","https://github.com/nuxt/test-utils/issues/795",0.72570074,{"description":3060,"labels":3061,"number":3063,"owner":3023,"repository":3023,"state":3024,"title":3064,"updated_at":3065,"url":3066,"score":3067},"### Environment\n\n## Issue Description\n\n### Problem\nNuxt 4's auto-import system has a limitation where functions exported from shared directories (e.g., `shared/utils/`) are globally auto-imported for Vue components, but TypeScript/editors don't recognize these functions when used within the same directory. This causes \"Cannot find name\" errors in development despite the code working correctly at runtime.\n\n### Example\nIn a typical setup with shared utilities:\n\n```typescript\n// shared/utils/typeGuards.ts\nexport const isArray = (value: any): value is any[] => Array.isArray(value)\n\n// shared/utils/numberHelpers.ts\nexport const toNumber = (v: unknown) => \n isArray(v) ? v.map(item => toNumber(item)) : Number(v) // ❌ Cannot find name 'isArray'\n```\n\nThe `isArray` function is available globally in Vue components but not recognized within the same `shared/utils/` directory.\n\n### Root Cause\nThe auto-import scanning in `packages/nuxt/src/imports/module.ts` only makes exports globally available but doesn't handle intra-directory imports. The `scanDirExports` function creates imports that work globally but not within the same directory scope.\n\n### Solution\nEnhanced the import scanning logic to create duplicate import entries for shared directories:\n\n1. **Identify shared directories**: Filter `composablesDirs` for paths containing `/shared/`\n2. **Create duplicate imports**: Generate additional import entries with special metadata for intra-directory access\n3. **Maintain compatibility**: Preserve existing global auto-import functionality\n\n### Implementation Details\nThe fix adds this logic to the `regenerateImports` function:\n\n```typescript\n// Add intra-directory imports for shared directories\nconst intraDirectoryImports: Import[] = []\nconst sharedDirs = composablesDirs.filter(dir => dir.includes('/shared/'))\nfor (const sharedDir of sharedDirs) {\n const dirImports = scannedImports.filter(imp => imp.from.startsWith(sharedDir))\n for (const imp of dirImports) {\n intraDirectoryImports.push({\n ...imp,\n meta: { ...imp.meta, intraDirectory: sharedDir }\n })\n }\n}\nimports.push(...scannedImports, ...intraDirectoryImports)\n```\n\n### Benefits\n- ✅ **TypeScript Support**: Eliminates \"Cannot find name\" errors in editors\n- ✅ **No Breaking Changes**: Maintains existing global auto-import behavior \n- ✅ **Better DX**: Enables seamless cross-file usage within shared directories\n- ✅ **Performance**: Minimal overhead, only affects shared directories\n",[3062],{"name":3020,"color":3021},32646,"fix(imports): enable intra-directory auto-imports for shared utilities","2025-07-16T20:09:35Z","https://github.com/nuxt/nuxt/issues/32646",0.7408666,{"description":3069,"labels":3070,"number":3071,"owner":3023,"repository":3072,"state":3024,"title":3073,"updated_at":3074,"url":3075,"score":3076},"### Environment\n\n- Operating System: Darwin\n- Node Version: v23.7.0\n- Nuxt Version: 3.15.4\n- CLI Version: 3.21.1\n- Nitro Version: 2.10.4\n- Package Manager: bun@1.2.2\n- Builder: -\n- User Config: extends, modules, devtools, runtimeConfig, future, compatibilityDate, site, hub, auth, content, image, eslint, css, colorMode\n- Runtime Modules: @nuxtjs/seo@2.1.1, @nuxt/image@1.9.0, @nuxt/ui-pro@3.0.0-alpha.13, @nuxt/content@3.1.1, @nuxthub/core@0.8.17, @nuxt/eslint@0.7.6, nuxt-auth-utils@0.5.15, nuxt-medusa@1.0.0, nuxt-particles@0.3.0, motion-v/nuxt@0.10.0\n- Build Modules: -\n\n### Version\n\nv3.0.0-alpha.12\n\n### Reproduction\n\nJusy load the animated icon anywhere in a page.\n\n\nFor example:\n\n```html\n\u003CIcon name=\"line-md:loading-twotone-loop\" />\n```\n\n### Description\n\nThe issue occurs both when I run the app in development mode and when I build it for production. I tested it on Safari (Mac and iPhone) and Chrome (iPhone only). On the first page load, the animation works fine, but when I reload the page, the animation stops. However, when the component where it is used updates, the icon state changes (still without animation). \n\nHere I placed some icons randomly in the pages to show the problem and when it occurs:\n\nhttps://github.com/user-attachments/assets/ca9772d8-61bb-47da-9b9e-38cbb8d5796c\n\n).",[],361,"icon","Icon is not animating correctly","2025-02-23T14:06:29Z","https://github.com/nuxt/icon/issues/361",0.74498385,{"description":3078,"labels":3079,"number":3087,"owner":3023,"repository":3088,"state":3089,"title":3090,"updated_at":3091,"url":3092,"score":3093},"### Environment\n\n- Operating System: Linux\n- Node Version: v20.17.0\n- Nuxt Version: ^3.13.0\n- CLI Version: 3.14.0\n- Package Manager: bun\n- Nuxt Ui: ^3.0.0-alpha.6\n\n\n### Version\n\n3.0.0-alpha.6\n\n### Reproduction\n\n1. Clone https://github.com/malte-baumann/z-index\n2. bun dev (or similar)\n3. Open modal / slideover / drawer\n4. Click on Select / DropdownMenu / InputMenu\n5. See what you don't see\n\n### Description\n\nI opend #2404 recently and noticed some more z-index problems. \nAt least these Components: \n- Select\n- DropdownMenu\n- InputMenu \ndon't have high enough z-indexes inside a Drawer / Modal / Slideover to show their popover contents. \n\n\n\n### Additional context\n\n\n\n\n### Logs\n\n_No response_",[3080,3081,3084],{"name":3036,"color":3037},{"name":3082,"color":3083},"duplicate","cfd3d7",{"name":3085,"color":3086},"v3","49DCB8",2421,"ui","closed","Z-Indexes inside Modal / Slideover / Drawer","2024-10-21T10:15:59Z","https://github.com/nuxt/ui/issues/2421",0.71052074,{"description":3095,"labels":3096,"number":3101,"owner":3023,"repository":3023,"state":3089,"title":3102,"updated_at":3103,"url":3104,"score":3105},"### Environment\n\n------------------------------\r\n- Operating System: Windows_NT\r\n- Node Version: v20.9.0\r\n- Nuxt Version: 3.8.2\r\n- CLI Version: 3.10.0\r\n- Nitro Version: 2.8.0\r\n- Package Manager: pnpm@8.3.1\r\n- Builder: -\r\n- User Config: alias, app, components, devtools, experimental, modules, nitro, runtimeConfig, session, sourcemap, typescript, vite, vue\r\n- Runtime Modules: @unocss/nuxt@0.57.7, @vueuse/nuxt@10.6.1\r\n- Build Modules: -\r\n------------------------------\n\n### Reproduction\n\nhttps://stackblitz.com/edit/github-6zhzee?file=services%2Fdemo%2Fworker.ts,pages%2Findex.vue\n\n### Describe the bug\n\nIn the webworker file, the referenced Auto-imports function will not be packaged, and will appear \"Uncaught (in promise) ReferenceError: log is not defined\r\n at globalThis.onmessage (worker-6dbb1795.js:1:255)\r\n\"\n\n### Additional context\n\nstep:\r\n1. pnpm build\r\n2. node .output/...\r\n3. see browser devtools console\n\n### Logs\n\n_No response_",[3097,3100],{"name":3098,"color":3099},"3.x","29bc7f",{"name":3020,"color":3021},24443,"Auto-imports in webworker bundle not work","2023-12-10T20:47:40Z","https://github.com/nuxt/nuxt/issues/24443",0.71346706,{"labels":3107,"number":3111,"owner":3023,"repository":3023,"state":3089,"title":3112,"updated_at":3113,"url":3114,"score":3115},[3108],{"name":3109,"color":3110},"2.x","d4c5f9",8414,"Build fails on code only used in development","2023-01-18T15:31:30Z","https://github.com/nuxt/nuxt/issues/8414",0.72836447,{"description":3117,"labels":3118,"number":3127,"owner":3023,"repository":3023,"state":3089,"title":3128,"updated_at":3129,"url":3130,"score":3131},"### Environment\r\n\r\nNuxi 3.1.2\r\n\r\nRootDir: *******\r\nNuxt project info:\r\n\r\n------------------------------\r\n- Operating System: ****\r\n- Node Version: `v16.13.2`\r\n- Nuxt Version: `2.16.2`\r\n- Nitro Version: `1.0.0`\r\n- Package Manager: `npm@8.1.2`\r\n- Builder: `webpack`\r\n- User Config: `bridge`, `head`, `css`, `plugins`, `components`, `buildModules`, `bootstrapVue`, `styleResources`, `ssr`, `target`, `modules`, `proxy`, `axios`, `auth`, `router`, `serverMiddleware`, `i18n`, `build`, `runtimeConfig`, `static`, `server`, `serverHandlers`, `devServerHandlers`, `devServer`, `typescript`\r\n- Runtime Modules: `@nuxtjs/axios@5.13.6`, `@nuxtjs/proxy@2.1.0`, `@nuxtjs/i18n@7.3.1`, `nuxt-prometheus-module@0.1.4`, `nuxt-datadog-trace@0.1.2`, `bootstrap-vue/nuxt`, `nuxt-session@1.0.3`, `express-session@1.17.3`, `express@4.18.2`, `cookie-universal-nuxt@2.2.2`\r\n- Build Modules: `()`, `@nuxtjs/stylelint-module@4.2.0`, `@nuxt/bridge@3.0.0-27928371.c30fa0f`\r\n------------------------------\r\n\r\n\r\n### Reproduction\r\n\r\nUpdated configuration and dependencies and tried to start server using bridge, as in the guide on nuxtjs page\r\n\r\n### Describe the bug\r\n\r\nThe server compile but cannot be started due to an error, even if compilation was succesfull\r\n\r\n### Additional context\r\n\r\nAfter compiling the index.mjs file appear to have a problem even if it was not reported any error (only a warning due to a import of jsPDF that should not be a problem\r\n\r\n```\r\n√ Server: Compiled successfully in 1.50m\r\n√ Client: Compiled successfully in 2.36m\r\n\r\n WARN Compiled with 1 warnings\r\n\r\n\r\n WARN in ./node_modules/fflate/esm/index.mjs\r\n\r\nModule not found: Error: Can't resolve 'worker_threads' in '*****\\node_modules\\fflate\\esm'\r\n\r\n√ Nitro built in 5581 ms\r\ni Waiting for file changes\r\n\r\n ERROR [worker reload] [worker init] require$$1 is not a function\r\n\r\n at ******/.nuxt/dev/index.mjs:443:13\r\n at ModuleJob.run (node:internal/modules/esm/module_job:185:25)\r\n at async Promise.all (index 0)\r\n at async ESMLoader.import (node:internal/modules/esm/loader:281:24)\r\n at async loadESM (node:internal/process/esm_loader:88:5)\r\n at async handleMainPromise (node:internal/modules/run_main:65:12)\r\n```\r\n\r\n\r\nInside file index.mjs I find (line 438 -443):\r\n\r\n```\r\nconst require$$0 = /*@__PURE__*/getDefaultExportFromNamespaceIfNotNamed(bodyParser$1);\r\n\r\nconst require$$1 = /*@__PURE__*/getDefaultExportFromNamespaceIfNotNamed(express);\r\n\r\nconst bodyParser = require$$0;\r\nconst app = require$$1();\r\n```\r\n\r\nthat is giving the error, the require$$1 is called as a function.\r\n\r\n\r\n\r\n### Logs\r\n\r\n_No response_",[3119,3120,3121,3124],{"name":3098,"color":3099},{"name":3020,"color":3021},{"name":3122,"color":3123},"needs reproduction","FBCA04",{"name":3125,"color":3126},"closed-by-bot","ededed",19581,"Errore in compiled index.mjs while using bridge to upgrade","2023-08-08T01:51:38Z","https://github.com/nuxt/nuxt/issues/19581",0.7323873,{"labels":3133,"number":3138,"owner":3023,"repository":3023,"state":3089,"title":3139,"updated_at":3140,"url":3141,"score":3142},[3134,3137],{"name":3135,"color":3136},"documentation","5319e7",{"name":3098,"color":3099},12747,"Importing and using nuxt3 functions directly does not work","2023-01-19T16:45:14Z","https://github.com/nuxt/nuxt/issues/12747",0.7340401,["Reactive",3144],{},["Set"],["ShallowReactive",3147],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fS2cN5vlqaA3zfQ1KMb5dGzfIwK4vaWX9Xtl3AcW2dF0":-1},"/nuxt/scripts/430"]