invictus-codes / nuxt-vuetify

Add Vuetify 3 to your Nuxt application in seconds.
MIT License
73 stars 9 forks source link

[Bug]: [vite-node] [ERR_LOAD_URL] vuetify/styles #20

Closed thejacer87 closed 11 months ago

thejacer87 commented 11 months ago

Contact Details

No response

What happened?

I installed the plugin per the instructions with pnpm: pnpm add -D @invictus.codes/nuxt-vuetify

When I start the Nuxt server I see this error in the console:

[10:41:01 p.m.]  ERROR  Failed to resolve import "vuetify/styles" from "virtual:nuxt:/path/to/my/project/.nuxt/css.mjs". Does the file exist?

[10:41:01 p.m.]  ERROR  Failed to resolve import "vuetify" from "virtual:nuxt:/path/to/my/project/.nuxt/templates.plugin.12f8b498.mts". Does the file exist?

And when I try to open any page, I see this: image

Version

1.0.2 (Default)

What browsers are you seeing the problem on?

Firefox, Chrome

Relevant log output

[10:41:01 p.m.]  ERROR  Failed to resolve import "vuetify/styles" from "virtual:nuxt:/path/to/my/project/.nuxt/css.mjs". Does the file exist?

[10:41:01 p.m.]  ERROR  Failed to resolve import "vuetify" from "virtual:nuxt:/path/to/my/project/.nuxt/templates.plugin.12f8b498.mts". Does the file exist?

Additional context

No response

thejacer87 commented 11 months ago

so it seems like my issue is related to something going on with nuxt and pnpm workspaces: https://github.com/nuxt/nuxt/issues/14146

i installed it from the root of the monorepo with pnpm -F myproj add -D @invictus.codes/nuxt-vuetify

if i install it directly in the project folder, it worked as expected

gwenf commented 8 months ago

I just wanted to add a comment here in case someone else runs into this issue. I was getting this error from npm run dev on a new Nuxt project after I added this nuxt-vuetify module.

Steps I used to resolve it:

  1. Made sure npm was up to date (currently working on Node 18.17.1 and npm 9.6.7)
  2. Deleted node_modules folder and the package-lock.json file
  3. Ran npm i again
  4. npm run dev now works