Open martinszeltins opened 1 year ago
@martinszeltins Thanks for the report. Don't know yet why this error happans. With nuxt 3.6.5 this works. So somehow nuxt 3.7.1 still has somthing wrong.
Update: Issue opened https://github.com/nuxt/nuxt/issues/23038
@martinszeltins Ok after some investigating i found a workaround for nuxt 3.7.1 . You can look there: https://github.com/nuxt/nuxt/issues/23038#issuecomment-1710268991
Still have this issue with a Many to Many relationship, no matter what i'm doing with vite and nuxt versions.
Just an FYI: It's also not solved by using Nuxt 3.8.0
Yeah i didn't try it since i had other problems with this new version, but thanks for testing it. I didn't try anything since my first post, i'll prob work on it within the week since it's blocking anyway.
Did someone figure something out by any chance ?
Nuxt 3.8.1
sadly doesn't have a fix for this either. The solution described here https://github.com/nuxt/nuxt/issues/23038 seems to be the only workaround right now.
Hey fellas! So I got this working with Nuxt 3.8.1 and Vite 5.0.0. Apparently it wasn't enough to add experimental decorators to my TS config, but add it to Nuxt config as well, like so:
export default defineNuxtConfig({
debug: true,
devtools: { enabled: true },
modules: ['@pinia/nuxt', '@pinia-orm/nuxt'],
typescript: {
typeCheck: true,
strict: true,
},
vite: {
esbuild: {
tsconfigRaw: {
compilerOptions: {
experimentalDecorators: true,
}
}
}
}
})
Got this workaround from here: https://github.com/vitejs/vite/issues/13736
Environment
Reproduction
https://github.com/martinszeltins/pinia-orm-new
Describe the bug
I am getting this error:
I have a very simple setup as you can tell from my reproduction repo. I just followed the docs.
And this is my usage just like in the docs: