Closed modbender closed 3 months ago
https://github.com/nuxt-modules/og-image/blob/6c8936d2d961571af64104c5abefba9bb7cf9291/src/module.ts#L341
Maybe it should be debug.json.mjs
here?
Ah, no, it's most likely related to nitro v2.9.2 including this PR: https://github.com/unjs/nitro/pull/2229
Ok looks like it indeed is nitro problem.
Add one of the below to package.json
"resolutions": {
"nitropack": "2.9.1"
}
OR
"overrides": {
"nitropack": "2.9.1"
}
Next, run npm install
or whichever CLI you use.
Ok looks like it indeed is nitro problem. Doing the below fixed it:
"resolutions": { "nitropack": "2.9.1" }
where did you add this, can you explain ? @modbender
!!!!! +++,
relax a bit please
then this error out of nowhere
without updating nitropack this issue should not occur
As you can see people are working on fixing that issue, please upvote the issue by giving it a :+1: instead of commenting without further information :pray:
where did you add this
To the package.json
@CODE-BR3AKER add it to package.json
Example from my project
{
"name": "nuxt-app",
"private": true,
"type": "module",
"scripts": {
"build": "nuxt build",
"dev": "nuxt dev",
"generate": "nuxt generate",
"preview": "nuxt preview",
"postinstall": "nuxt prepare"
},
"devDependencies": {
"@nuxtjs/color-mode": "^3.3.2",
"@nuxtjs/seo": "2.0.0-rc.8",
"nuxt": "^3.10.3",
"nuxt-bootstrap-css": "^1.1.0",
"nuxt-icon": "^0.6.9",
"sass": "^1.71.1",
"vue": "^3.4.21",
"vue-router": "^4.3.0"
},
"resolutions": {
"nitropack": "2.9.1"
}
}
Sorry I just been debuging this issue for 2 hours & I cannot seem to fix it :/
I tried btw your proposed solution + removed node_modules, pkg lock , did a fresh npm install, but still same issue. ( I see somehow that nuxt dev ignores the resolutions & uses nitro 2.9.2) Any help is truly appreciated :pray:
You have to add it to package.json and run install npm install
or yarn install
or pnpm install
Call it overrides
instead of resolutions
(https://stackoverflow.com/a/67397982)
(@harlan-zw please mark those comments as offtopic)
Here's the Nuxt issue: https://github.com/nuxt/nuxt/issues/26168
I have the same issue in my project
Again, please upvote the issue by giving it a 👍 instead of commenting without further information 🙏
@dargmuesli can you get this fixed today? whats the hold up?
There no need to have this issue in a personal project, a workaround has been provided above.
@danielroe if I may ask for some moderation on the comments above at your discretion? Thanks :raised_hands:
Regression re json should be fixed in latest nitro release (https://github.com/unjs/nitro/pull/2239)
Just till recently (less than a week ago) I had no problem using
@nuxtjs/seo
, but suddenly using the package gives me error:Environment:
WSL Ubuntu (Windows 11)
Build Modules: -
Error
Error when using yarn:
Error when using pnpm:
npx nuxi@latest init <project-name>
pnpm add -D @nuxtjs/seo
and add it tomodules
pnpm dev
.What's in the installation
I went ahead and checked the installation path of nuxt-og-image, and indeed it seems like there's no debug.json, I don't know if .d.ts and .mjs gets resolved into debug.json though
Things I have tried
I have tried switching from
pnpm
toyarn
.I have tried previous versions of
nuxt
,vue
,vue-router
I have tried previous versions:
I have also tried some old versions of
nuxt-og-image
. I know the current version is"nuxt-og-image": "3.0.0-rc.42"
and I have tried tillrc.37
, which was part of a different project that WAS working perfectly fine...I have also seen a similar issue and tried steps from it
At the end this might be an issue related to this project or not, but hoping I get some help.