\n```\n\nOn 4.0.3, `npx nuxt typecheck` works fine. On 4.1.0, I get `error TS7006: Parameter 'v' implicitly has an 'any' type.`\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell-script\n\n```",[3201,3202,3205,3206],{"name":3173,"color":3174},{"name":3203,"color":3204},"✨ good reproduction","fbca04",{"name":3160,"color":3161},{"name":3207,"color":3208},"possible regression","B90A42",33142,"defineEmits types not being registered","2025-09-05T08:30:05Z","https://github.com/nuxt/nuxt/issues/33142",0.66067034,{"description":3215,"labels":3216,"number":3221,"owner":3163,"repository":3163,"state":3181,"title":3222,"updated_at":3223,"url":3224,"score":3225},"### Environment\r\n\r\n- Operating System: Linux\r\n- Node Version: v20.5.1\r\n- Nuxt Version: 3.7.0\r\n- CLI Version: 3.7.2\r\n- Nitro Version: 2.6.2\r\n- Package Manager: npm@9.8.1\r\n- Builder: -\r\n- User Config: devtools\r\n- Runtime Modules: -\r\n- Build Modules: -\r\n\r\n### Reproduction\r\n\r\nthis is a fresh project install with the nuxt latest version\r\n\r\n### Describe the bug\r\n\r\nOn a fresh installed project\r\n\r\nEach time I wanna use an auto-imported module, I got a TS error like this: \r\n\r\nCannot find name 'useHeader'.ts(2304)\r\nor\r\nCannot find name 'useAsyncData'.ts(2304)\r\n(even useFetch etc...)\r\n\r\n\r\n\r\nthe error desapear when I remove lang=\"ts\"\r\n\r\nhere the tsconfig: \r\n\r\n```\r\n{\r\n // https://nuxt.com/docs/guide/concepts/typescript\r\n \"extends\": \"./.nuxt/tsconfig.json\",\r\n}\r\n```\r\n\r\nnuxt.config.ts: \r\n```\r\n// https://nuxt.com/docs/api/configuration/nuxt-config\r\nexport default defineNuxtConfig({\r\n devtools: { enabled: true },\r\n})\r\n\r\n```\r\n\r\nAlso have these kind of errors on Nitro part (on the non-fresh-app):\r\n\r\n\r\n\r\n\r\nTried to reinstall my VSCODE completely\r\n\r\n### Additional context\r\n\r\npackage.json: (fresh installed app)\r\n```\r\n{\r\n \"name\": \"nuxt-app\",\r\n \"private\": true,\r\n \"scripts\": {\r\n \"build\": \"nuxt build\",\r\n \"dev\": \"nuxt dev\",\r\n \"generate\": \"nuxt generate\",\r\n \"preview\": \"nuxt preview\",\r\n \"postinstall\": \"nuxt prepare\"\r\n },\r\n \"devDependencies\": {\r\n \"@nuxt/devtools\": \"latest\",\r\n \"@types/node\": \"^20.5.7\",\r\n \"nuxt\": \"^3.7.0\"\r\n }\r\n}\r\n\r\n```\r\n\r\n\r\n_No response_\r\n\r\n### Logs\r\n\r\n_No response_",[3217,3218],{"name":3176,"color":3177},{"name":3219,"color":3220},"pending triage","E99695",22874,"3.7: New project or existant: TS errors with auto-import (useFetch, useHeader etc...)","2023-08-28T22:53:19Z","https://github.com/nuxt/nuxt/issues/22874",0.66090053,{"description":3227,"labels":3228,"number":3231,"owner":3163,"repository":3163,"state":3181,"title":3232,"updated_at":3233,"url":3234,"score":3235},"### Environment\n\n------------------------------\r\n- Operating System: `Windows_NT`\r\n- Node Version: `v16.19.1`\r\n- Nuxt Version: `0.0.0`\r\n- Nitro Version: `-`\r\n- Package Manager: `unknown`\r\n- Builder: `webpack`\r\n- User Config: `-`\r\n- Runtime Modules: `-`\r\n- Build Modules: `-`\r\n------------------------------\r\n\n\n### Reproduction\n\nCopy paste the `modules` from the Nuxt Documentation.\r\n\r\n```\r\nimport { defineNuxtConfig } from 'nuxt/config';\r\n\r\nexport default defineNuxtConfig({\r\n modules: [\r\n // Using package name\r\n '@nuxtjs/axios',\r\n // Relative to your project srcDir\r\n '~/modules/awesome.js',\r\n // Providing options\r\n ['@nuxtjs/google-analytics', { ua: 'X1234567' }],\r\n // Inline definition\r\n function () {},\r\n ],\r\n});\r\n```\n\n### Describe the bug\n\nThis started to happen when I updated from nuxt 3.3.0 to 3.4.2.\r\n\r\n\r\n\n\n### Additional context\n\n_No response_\n\n### Logs\n\n_No response_",[3229,3230],{"name":3176,"color":3177},{"name":3219,"color":3220},20524,"TS2589: Type instantiation is excessively deep and possibly infinite","2023-10-02T12:08:20Z","https://github.com/nuxt/nuxt/issues/20524",0.6621476,{"description":3237,"labels":3238,"number":3241,"owner":3163,"repository":3163,"state":3181,"title":3242,"updated_at":3243,"url":3244,"score":3245},"Not sure if this belongs here. Feels like it doesn't belong in the Nuxt repo either, because it's module specific. Let me know if I need to move it.\r\n\r\nSo my situation is the following. I'm further improving my [Nuxt-vuetify module](https://github.com/invictus-codes/nuxt-vuetify). Users of the module, will provide a Vuetify config through the Nuxt.config.ts. Now Vuetify has the following feature when it comes to icons, [fa-svg](https://vuetifyjs.com/en/features/icon-fonts/#font-awesome-svg-icons). To use this feature, you need to provide a function as iconSet (component). This is how it works, I cannot change this. However, this is not the cause of my \"issue\".\r\n\r\nWhat I can't seem to get working is the following, tested it on the nuxt-module-starter:\r\n\r\nIn my Nuxt.config.ts:\r\n```typescript\r\nexport default defineNuxtConfig({\r\n modules: [\"../src/module\"],\r\n myModule: {\r\n testViaConfig() {\r\n console.log(\"test\");\r\n return \"test\";\r\n },\r\n },\r\n});\r\n```\r\n\r\nin my module.ts:\r\n```typescript\r\nimport { defineNuxtModule, addPlugin, createResolver } from \"@nuxt/kit\";\r\n\r\n// Module options TypeScript interface definition\r\nexport interface ModuleOptions {}\r\n\r\nexport default defineNuxtModule\u003CModuleOptions>({\r\n meta: {\r\n name: \"my-module\",\r\n configKey: \"myModule\",\r\n },\r\n // Default configuration options of the Nuxt module\r\n defaults: {},\r\n setup(options, nuxt) {\r\n const resolver = createResolver(import.meta.url);\r\n\r\n nuxt.options.runtimeConfig.public.myModule = {\r\n ...options,\r\n test: \"runtimeConfig, check\",\r\n testViaModule: () => {\r\n console.log(\"test\");\r\n return \"test\";\r\n },\r\n };\r\n // Do not add the extension since the `.ts` will be transpiled to `.mjs` after `npm run prepack`\r\n addPlugin(resolver.resolve(\"./runtime/plugin\"));\r\n },\r\n});\r\n```\r\n\r\nIn my runtime/plugin.ts:\r\n```typescript\r\nimport { defineNuxtPlugin, useRuntimeConfig } from \"#app\";\r\n\r\nexport default defineNuxtPlugin((nuxtApp) => {\r\n const config = useRuntimeConfig();\r\n const options = config.public.myModule;\r\n console.log({ options });\r\n console.log(\"Plugin injected by my-module!\");\r\n});\r\n```\r\n\r\nI would expect that in the browser both the `testViaConfig` and `testViaModule` functions would be logged. Except only the string (defined in module.ts, also passed via runtimeConfig), is logged in the browser.\r\n\r\nI have made a codesandbox to reproduce. You can find it [here](https://codesandbox.io/p/github/jvhellemondt/nuxt-module-starter/draft/trusting-galileo?file=%2Fsrc%2Fmodule.ts&workspaceId=26bac05a-e35e-485b-bb0f-53f697bee73f).\r\n\r\nIs it intended that I cannot pass functions to runtime like this? I have the feeling that it's not possible due to rollup, however I'm definitely not an expert on that. If so, is there another way around? It seems vital that users of the module can provide it via the Nuxt.config.ts from a user experience perspective.\r\n\r\nHope someone is able to help out. If I need to explain further, please let me know.\r\n\r\nThank you in advance.\r\n\r\nBest regards,\r\n\r\nJ",[3239,3240],{"name":3176,"color":3177},{"name":3219,"color":3220},20933,"Question/ bug: How to provide functions from within Nuxt.config.ts or module.ts to runtime?","2024-04-17T06:42:23Z","https://github.com/nuxt/nuxt/issues/20933",0.66588634,{"labels":3247,"number":3250,"owner":3163,"repository":3163,"state":3181,"title":3251,"updated_at":3252,"url":3253,"score":3254},[3248,3249],{"name":3176,"color":3177},{"name":3219,"color":3220},14561,"Type errors in generated `components.d.ts`","2023-01-19T17:37:13Z","https://github.com/nuxt/nuxt/issues/14561",0.6674464,{"description":3256,"labels":3257,"number":3260,"owner":3163,"repository":3163,"state":3181,"title":3261,"updated_at":3262,"url":3263,"score":3264},"### Environment\r\n\r\n- Operating System: `Darwin`\r\n- Node Version: `v20.10.0`\r\n- Nuxt Version: `3.9.3`\r\n- CLI Version: `3.10.0`\r\n- Nitro Version: `2.8.1`\r\n- Package Manager: `npm@10.2.3`\r\n- Builder: `-`\r\n- User Config: `modules`, `css`, `runtimeConfig`, `sanity`, `lodash`, `devServer`, `server`, `ssr`, `app`, `vue`, `sitemap`, `robots`, `routeRules`\r\n- Runtime Modules: `@nuxtjs/tailwindcss@6.8.0`, `@nuxtjs/sanity@1.8.1`, `nuxt-lodash@2.5.0`, `@pinia/nuxt@0.4.11`, `nuxt-simple-robots@2.3.0`\r\n- Build Modules: `-`\r\n\r\n\r\n### Reproduction\r\n\r\ncreate any `plugin` and provide something, for example `dayjs.ts`:\r\n\r\n```\r\nimport dayjs from 'dayjs'\r\n\r\nexport default defineNuxtPlugin((nuxtApp) => {\r\n nuxtApp.provide('dayjs', dayjs)\r\n})\r\n\r\n```\r\n\r\n### Describe the bug\r\n\r\nwhen we want to use it in our `.vue`, there is no autocomplete for it. to have the types we have to add this into our plugin:\r\n\r\n```\r\ndeclare module '#app' {\r\n interface NuxtApp {\r\n $dayjs: typeof dayjs\r\n }\r\n}\r\n```\r\n\r\n\r\nin the documentation there is no reference of declaring [`NuxtApp interface`](https://nuxt.com/docs/api/composables/use-nuxt-app)\r\n\r\n\r\nshould we add that to documentation?\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Logs\r\n\r\n_No response_",[3258,3259],{"name":3176,"color":3177},{"name":3219,"color":3220},25595,"useNuxtApp provide type","2024-02-03T03:46:17Z","https://github.com/nuxt/nuxt/issues/25595",0.66983914,{"description":3266,"labels":3267,"number":3269,"owner":3163,"repository":3163,"state":3181,"title":3270,"updated_at":3271,"url":3272,"score":3273},"### Describe the bug\n\nHello Nuxt Team,\n\nI am encountering an issue with nuxi prepare that affects TypeScript imports in a Nuxt module. While imports and TypeScript declarations are correctly generated and recognized in the Playground, they do not work in the main module. This leads to TypeScript errors, even though the code runs perfectly at runtime.\n\nProblem Description:\n\nCorrect Imports in the Playground:\nWhen using the module in the Playground, all composables and components are correctly registered in .nuxt/types/imports.d.ts. TypeScript recognizes them without any issues, and there are no error messages.\n\nBroken Imports in the Main Module:\nWhen using the same composables or modules in the main module, a TypeScript error occurs: \"Cannot find name 'useExample',\" even though the function exists and is correctly implemented. This issue happens even with proper tsconfig configuration and does not affect runtime behavior.\n\n\nI added the test project.\n[my-module.zip](https://github.com/user-attachments/files/17819639/my-module.zip)\n\n\nThank you for your support!\n\n### Environment\n\nNuxt Version: [3.14.159]\nNode Version: [v20.17.0]\nBuild Tool: Vite\nIDE: WebStorm\n\n### Reproduction\n\nSteps to Reproduce:\n\nCreate a new Nuxt module:\n\n```\nnpx nuxi init -t module my-module\ncd my-module\nnpm install\n```\nRegister a simple composable in the module, e.g., in src/runtime/composables/test.ts:\n\n```\nexport const useExample = () => {\n return \"This is an example composable.\";\n};\n```\nConfigure the module in module.ts:\n\n```\nimport { defineNuxtModule, addImportsDir, createResolver } from '@nuxt/kit';\n\nexport default defineNuxtModule({\n meta: {\n name: 'my-module',\n configKey: 'myModule',\n },\n async setup(_, nuxt) {\n const resolver = createResolver(import.meta.url);\n\n // Composables\n const composableDirs = [\n resolver.resolve('./runtime/composables'),\n ];\n addImportsDir(composableDirs);\n },\n});\n```\nUse the composable inside a component within the module, e.g., in src/runtime/components/test2/index.vue:\n\n```\n\n\u003Cscript setup lang=\"ts\">\nconst example = useExample();\n\u003C/script>\n```\nAfter running nuxi prepare, TypeScript in the IDE (e.g., WebStorm) shows the error:\n\nCannot find name 'useExample'.\nCheck the generated .nuxt/types/imports.d.ts file: The composable is not registered, even though it works correctly at runtime.\n\n\nExpected Behavior:\n\nnuxi prepare should generate TypeScript declarations and auto-imports consistently for both the Playground and the main module.\nComposables should be recognized by TypeScript without any errors.\n\n\n\n### Additional context\n\nAdditional Context:\nThis issue is not limited to composables. It also affects other elements like Pinia stores, i18n functions, and any non-standard Nuxt features. These are also not correctly registered in the generated TypeScript declarations, causing errors in the development environment (IDE), even though everything works fine at runtime.\n\n\n### Logs\n\n```shell-script\n\n```",[3268],{"name":3219,"color":3220},29979,"Issue with nuxi prepare: Imports work in the Playground but not in the Main Module","2024-11-20T07:13:51Z","https://github.com/nuxt/nuxt/issues/29979",0.6714744,["Reactive",3275],{},["Set"],["ShallowReactive",3278],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fVjuYUMrgUa5BIOkFxNtPqAVOT81zEw_HIm5k3IcPxVU":-1},"/nuxt/ui/2085"]