Skip to content

Error 500 Unexpected token ':' with Nuxt v3.9+ #67

@codeflorist

Description

@codeflorist

Using this package with Nuxt versions higher than v3.8 throws the following error:

[nuxt] [request error] [unhandled] [500] Unexpected token ':'
  at __global_eval__ (https://nuxtstartererkavw-jwoc.w-credentialless.staticblitz.com/blitz.a9c8a5a3.js:1:263)  
  at _0x34b0d0 (https://nuxtstartererkavw-jwoc.w-credentialless.staticblitz.com/blitz.a9c8a5a3.js:352:197648)  
  at Script.runInContext (https://nuxtstartererkavw-jwoc.w-credentialless.staticblitz.com/blitz.a9c8a5a3.js:352:196823)  
  at Script.runInThisContext (https://nuxtstartererkavw-jwoc.w-credentialless.staticblitz.com/blitz.a9c8a5a3.js:74:1318)  
  at Object.runInThisContext (https://nuxtstartererkavw-jwoc.w-credentialless.staticblitz.com/blitz.a9c8a5a3.js:74:3926)  
  at ViteNodeRunner.runModule (./node_modules/vite-node/dist/client.mjs:378:32)  
  at ViteNodeRunner.directRequest (./node_modules/vite-node/dist/client.mjs:363:16)  
  at async ViteNodeRunner.cachedRequest (./node_modules/vite-node/dist/client.mjs:206:14)  
  at async ViteNodeRunner.dependencyRequest (./node_modules/vite-node/dist/client.mjs:250:12)  
  at async eval (./app.vue:1:216)

here is a reproduction:
https://stackblitz.com/edit/nuxt-starter-erkavw?file=package.json

changing nuxt dependency to ~3.8.0 fixes the problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions