You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@sentry/nuxt built package file located at /build/module/runtime/plugins/sentry.client.d.ts is empty. No types are exported, therefore the NuxtAppInjection type built by Nuxt fails and resolves to any which breaks every subsequent type of plugins used as, e.g.useNuxtApp().$pinia
Example in .nuxt/types/plugins.d.ts
typeNuxtAppInjections=InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/revive-payload.client.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/head/runtime/plugins/unhead.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/pages/runtime/plugins/router.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/payload.client.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/navigation-repaint.client.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/check-outdated-build.client.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/revive-payload.server.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/app/plugins/chunk-reload.client.js").default>&InjectionType<typeofimport("../../node_modules/@pinia/nuxt/dist/runtime/plugin.vue3.js").default>&InjectionType<typeofimport("../../node_modules/nuxt/dist/pages/runtime/plugins/prefetch.client.js").default>&InjectionType<typeofimport("../../node_modules/@sentry/nuxt/build/module/runtime/plugins/sentry.client.js").default>&// fails, resolves to `any`InjectionType<typeofimport("../../plugins/error").default>&InjectionType<typeofimport("../../plugins/fds").default>&InjectionType<typeofimport("../../plugins/locale").default>&InjectionType<typeofimport("../../plugins/routes").default>&InjectionType<typeofimport("../../plugins/store").default>
Steps to Reproduce
Install @sentry/nuxt, run nuxt so that the types are generated.
If you had any use of plugins like useNuxtApp().$pinia or so on, they are resolved to unknown which breaks the type-checking.
Expected Result
File /build/module/runtime/plugins/sentry.client.d.ts must export at least:
declareconst_default: any;exportdefault_default;
(Would be even better if it had the full type.)
Actual Result
File is empty.
The text was updated successfully, but these errors were encountered:
[Nuxt module builder](https://github.com/nuxt/module-builder) uses the
closest `tsconfig.json` and this had `"declaration": false`. I added
another `tsconfig.json` closer to the module to generate those
declarations.
fixes#13899
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/nuxt
SDK Version
8.33.1
Framework Version
Nuxt 3.13.2
Link to Sentry event
No response
Reproduction Example/SDK Setup
@sentry/nuxt
built package file located at /build/module/runtime/plugins/sentry.client.d.ts is empty. No types are exported, therefore theNuxtAppInjection
type built by Nuxt fails and resolves toany
which breaks every subsequent type of plugins used as, e.g.useNuxtApp().$pinia
Example in
.nuxt/types/plugins.d.ts
Steps to Reproduce
Install
@sentry/nuxt
, run nuxt so that the types are generated.If you had any use of plugins like
useNuxtApp().$pinia
or so on, they are resolved tounknown
which breaks the type-checking.Expected Result
File /build/module/runtime/plugins/sentry.client.d.ts must export at least:
(Would be even better if it had the full type.)
Actual Result
File is empty.
The text was updated successfully, but these errors were encountered: