Skip to content
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

Nuxt build not working with v2.0.0 and the latest Nuxt RC #89

Closed
FieldMarshallVague opened this issue Jun 10, 2022 · 4 comments
Closed

Comments

@FieldMarshallVague
Copy link

FieldMarshallVague commented Jun 10, 2022

Hi there,

I've just done an 'npm update' (I saw there was an update to RC and the google fonts packages) and I'm getting an error when I run

 npm run dev -- -o

I've removed package.lock and rm rf'd the modules folder. It just doesn't seem to like the combo of latest RC and v2.0.0.

I have seen other issues like this that seem to have some tie-in with Tailwind, which I'm not using.

I can roll back to v1.3.0 no problem, but just thought I'd let you know, since I was hoping v2 would solve an issue my colleague is having with fonts not loading (he's using local files for now).

Anyway, here's the error:

> dev
> nuxi dev
Nuxt CLI v3.0.0-rc.3-27579668.27a0084                                                                                                                                                                                                                   09:38:03
                                                                                                                                                                                                                                                        09:38:03
  > Local:    http://localhost:3000/
  > Network:  http://172.31.16.1:3000/
  > Network:  http://192.168.1.144:3000/

Cannot start nuxt:  Cannot read properties of undefined (reading 'resolveAlias')                                                                                                                                                              09:43:02

  at node_modules\@nuxtjs\google-fonts\dist\module.js:59:44
  at /C:/projects/test/repos/test/node_modules/hookable/dist/index.mjs:39:70
  at async build (/C:/projects/test/repos/test/node_modules/nuxt/dist/index.mjs:1646:3)
  at async Promise.all (index 1)
  at async load (/C:/projects/test/repos/test/node_modules/nuxi/dist/chunks/dev.mjs:6742:9)
  at async _applyPromised (/C:/projects/test/repos/test/node_modules/nuxi/dist/chunks/dev.mjs:6692:10)
@dan-online
Copy link

+1

I also have the same issue on nuxt@3.0.0-rc.3

@vadim656
Copy link

don`t working
"nuxt": "3.0.0-rc.4"

@mino89
Copy link

mino89 commented Jun 27, 2022

+1
same on nuxt@3.0.0-rc.4

it's caused by this line related to download configuration

...
if (options.download) {
      const outputDir = this.nuxt.resolver.resolveAlias(options.outputDir);
      try {
        await googleFontsHelper.GoogleFontsHelper.download(url, {
          base64: options.base64,
          overwriting: options.overwriting,
...

this.nuxt.resolver gives undefined when i try to log

mino89 pushed a commit to mino89/google-fonts-module that referenced this issue Jun 27, 2022
@ricardogobbosouza
Copy link
Collaborator

Try v3.0.0-0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants