-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ERROR [worker reload] [worker init] ../.nuxt/dev/index.mjs failed #6712
Comments
Having the exact same problem. Just started a Nuxt 3 project, then added PrimeVue following the docs, and I can't start it unless I remove PrimeVue. EDIT: tried installing 4.1.1. Throws the same error. Can only continue by removing PrimeVue from the project. |
Yes, I have met the same issue, both under the developement/production mode. I tried to install 4.2.0, 4.1.1, 4.1.0. All throw the same error.
Seems the issue caused by invoking the Here: primevue/packages/nuxt-module/src/module.ts Line 105 in 7053618
I changed to const runtimeConfig = undefined; , works well.
Cannot use @molul I am using patch-package to patch the local-installed |
Can confirm the fix by @wangziling . Strange that it wasn't happening earlier this week, but thankful for the quick workaround to keep moving! |
Can confirm the same issue. |
same here. |
I also upgraded to 4.2.1 and I got: |
I guess it should be related to nitropack version 2.10, I installed nitropack version 2.9.7 and it works fine. The problem is the location of the definition of In version 2.9, the definition of In version 2.10, the location of the definition of I'm not sure if this is a nitropack problem or a primevue one, but the current solution seems to be to downgrade the nitropack version to 2 9.7. It looks like you can't use This may affect more than just primevue's packages, so I'll try to open an issue there as well. This is a description of nitro's use of It seems to say that it can only be used in functions that start with define, but it's just that the way nitro builds itself allows |
@kiki-kanri i've just asked on twitter and pi0 said they're already investigating, so it seems to be a nitro problem |
Using 4.1.1 (previously deleting .nuxt folder, node_modules folfder and package-lock.json) doesn't fix the issue on my project. This is my package.json:
I get the same error message. |
Try install [email protected]. Here are the current solutions. |
It worked. Thanks! |
I didn't get the same error message since my nuxt project had already been created before. Sorry for that. Please try @kiki-kanri answer |
Thank you for all the detailed reports and workarounds 👏 The comments contain very valuable insights. For now, let's wait for a response from NitroPack. Once we hear back, we can decide together on any changes needed. I'm pinning this issue so we can also gather more user feedback in the meantime. |
✅ Nitro 2.10.1 is released with a fix. Recreating lock-file should solve the problem (tested against reproduction). |
I've just upgraded to primevue 4.2.1 and there were no errors. Thank you so much @pi0 🫱🏻🫲🏻. |
Thanks~ 😉 |
Wow! Thank you so much for your effort! Nitro man, @pi0 🚀 |
Huge thanks! |
@pi0 , I had a similar problem ( nuxt/nuxt#29767 ) and this version
My
|
Solved in 2.10.2 |
Excellent! I just tested it and it was resolved |
Just delete yarn.lock or npm.lock file and reinstall the dependencies to upgrade the nitro to 2.10.2 or higher version and then the error will disappear |
It is not solved, i don't think its because of primevue or other dependency, i am getting this error fully random not after installing a library. and it's basically unsolvable lol. Time to leave nuxt. |
Did you try setting up a fresh new project? I did and it vanished. I also updated npm and node just in case. |
Also with 2.10.2 i continue to have the same error :( |
Hey @plcdnl. Could you share your config? Or maybe share your repo |
Sorry @j0rgedev my problem was related to @nuxt/sanity |
Same here ! It's complety random Are you on WSL with admin rights that change on your machine? |
@maximedotair no, i'm on local with fresh nuxt project. It started happening again. Actually it has fix but it doesn't tell you what is the issue, check your syntax at @/server folder if any. Life could be much easier if it would tell where is the damn error lol. @lpknv I dont think i want to move my code to new project every damn time this happens, there is issue behind but it hides. Rather than telling the error it shutdowns whole project. Check your Adding this to "overrides": {
"nitropack": "2.9.7"
} |
For those who are still having issues. Could you share any reproduction? |
I created a fresh nuxt 3.14 project, installed primevue and it works. Here is the package.json file {
"name": "nuxt-app",
"private": true,
"type": "module",
"scripts": {
"build": "nuxt build",
"dev": "nuxt dev",
"generate": "nuxt generate",
"preview": "nuxt preview",
"postinstall": "nuxt prepare"
},
"dependencies": {
"@primevue/themes": "^4.2.1",
"nuxt": "^3.14.159",
"primevue": "^4.2.1",
"vue": "latest",
"vue-router": "latest"
},
"devDependencies": {
"@primevue/nuxt-module": "^4.2.1"
}
} Here is the nuxt.config.ts file import Aura from '@primevue/themes/aura';
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
compatibilityDate: '2024-04-03',
devtools: { enabled: true },
modules: ['@primevue/nuxt-module'],
primevue: {
options: {
theme: {
preset: Aura,
},
},
},
}); And finally a Button in the app.vue <template>
<div>
<Button label="Submit" />
</div>
</template> |
Describe the bug
Cannot run the project after adding primevue, the project is just the nuxt starter code and no other packages installed.
nuxt.config.ts
I am using nuxt v3.13.2 vue latest (3.5) and primevue v4.2.1
It gives the error in the title and never loads the app in browser (stuck on the nuxt loading screen)
Reproducer
https://stackblitz.com/edit/nuxt-starter-vhvkfm
PrimeVue version
4.2.1
Vue version
4.x
Language
ALL
Build / Runtime
Nuxt
Browser(s)
All
Steps to reproduce the behavior
No response
Expected behavior
No response
The text was updated successfully, but these errors were encountered: