nuxt-booster icon indicating copy to clipboard operation
nuxt-booster copied to clipboard

ERROR Error while requiring module nuxt-speedkit: TypeError: _consola.default.withTag is not a function

Open learntheropes opened this issue 2 years ago • 3 comments

Describe the bug The app does not build correctly due to an error, The error is:

ERROR  Error while requiring module nuxt-speedkit: TypeError: _consola.default.withTag is not a function 

To Reproduce Steps to reproduce the behavior:

  1. Install the package
  2. Copy the doc default settings in your project
  3. Run npm run dev
  4. See error

Expected behavior The app should build without any error, as it does without this module. A clear and concise description of what you expected to happen.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. brave.]
  • Version [e.g. 1.56.11]

learntheropes avatar Jul 25 '23 09:07 learntheropes

Hello @learntheropes ,

Which nuxt and node version are you using?

It is quite strange, could you put the dependency consola in your build trnaspile?

e.g. build.transpile = ['consola'];

ThornWalli avatar Jul 25 '23 11:07 ThornWalli

When I opened the issue, I was with node 16.x with nuxt 3.6.5.

I just tested again with:

------------------------------
- Operating System: Linux
- Node Version:     v18.17.0
- Nuxt Version:     3.7.0
- CLI Version:      3.7.3
- Nitro Version:    2.6.2
- Package Manager:  [email protected]
- Builder:          -
- User Config:      $production, app, runtimeConfig, css, components, modules, robots, sitemap, content, i18n, image, nitro, speedkit, delayHydration, build, appConfig
- Runtime Modules:  [email protected], [email protected], @nuxt/[email protected], @nuxtjs/[email protected], @nuxt/[email protected], [email protected], [email protected], [email protected]
- Build Modules:    -
------------------------------

And I have the same issue.

build: { transpile: ['consola']} does not fix it.`

Now I'm with nuxt-speedkit 2.2.3 and I guess it was the same when I tested the first time.

learntheropes avatar Aug 31 '23 22:08 learntheropes

@learntheropes Can you check which version node_modules/consola has in your project? Is it missing? or is an older version active.

ThornWalli avatar Sep 11 '23 13:09 ThornWalli

This is a version 2 problem, it is no longer maintained.

ThornWalli avatar May 04 '24 08:05 ThornWalli