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

Element missing end tag in <NuxtWelcome /> component after recent update. #22383

Closed
youngcadam opened this issue Jul 28, 2023 · 6 comments
Closed

Comments

@youngcadam
Copy link

Environment


  • Operating System: Linux
  • Node Version: v16.20.0
  • Nuxt Version: 3.6.5
  • Nitro Version: 2.5.2
  • Package Manager: [email protected]
  • Builder: vite
  • User Config: devtools
  • Runtime Modules: -
  • Build Modules: -

Reproduction

Somewhat surprising it hasn't been noticed yet but this bug is occurring in the StackBlitz environment linked on the Installation page in Nuxt's documentation https://stackblitz.com/github/nuxt/starter/tree/v3-stackblitz
image
and locally when I attempt to do the following

npx nuxi init test
cd test
npm install
npm run dev -- -o

image

Describe the bug

500 error caused by lack of end tag in node_modules/@nuxt/ui-templates/dist/templates/welcome.vue

image
Seems to be related to 9741f26 and changes to @nuxt/ui-templates mixing with vite-plugin-vue-inspector
image
Safe to say I am not the only one experiencing this given it is occurring in one of nuxt's featured starter environments.

Additional context

Noticed this started happening when I build new nuxt applications in the past week or so and believe this coincides with these recent changes 9741f26

Here is a screenshot of logs from browser that were too long to post:
image

Logs

Logs from `npm run dev`output:
ERROR  Internal server error: Element is missing end tag.                                        3:50:08 PM
  Plugin: vite-plugin-vue-inspector
  File: C:/Users/ayoung.PRESCIENT/firefly/node_modules/@nuxt/ui-templates/dist/templates/welcome.vue
      at createCompilerError (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:18:17)
      at emitError (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:1487:5)
      at parseElement (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:1031:5)
      at parseChildren (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:844:18)
      at parseElement (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:1008:20)
      at parseChildren (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:844:18)
      at parseElement (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:1008:20)
      at parseChildren (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:844:18)
      at parseElement (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:1008:20)
      at parseChildren (C:\Users\ayoung.PRESCIENT\firefly\node_modules\@vue\compiler-core\dist\compiler-core.cjs.js:844:18) (x2)
@wondenge
Copy link

wondenge commented Jul 28, 2023

I was also bootstrapping a new app this evening and run to the same issue. I can confirm that we have the same errors. I can reproduce and provide more context if needed.My case is in a local environment.

@LynxTR
Copy link

LynxTR commented Jul 28, 2023

I am having this issue on cloudflare's pages deployment as well

@danielroe
Copy link
Member

danielroe commented Jul 29, 2023

Thanks. This was (likely) triggered by a release of @nuxt/ui-templates. On it.

@ggoodwin
Copy link

For anyone looking for a workaround. Open this file.

node_modules>@nuxt>ui-templates>dist>templates>welcome.vue

Search the the following tag:

<nuxtwelcome>

and replace it with:

<nuxtwelcome />

Save and re-run the dev server script.

@danielroe
Copy link
Member

danielroe commented Jul 29, 2023

The issue is resolved upstream in nuxt/ui-templates@0341634 and in the release of v1.3.1.

You can pull this in by refreshing your lockfile or running the appropriate upgrade command for your package manager (e.g. npm upgrade @nuxt/ui-templates).

I've raised an upstream issue in GoogleChromeLabs/critters#132.

@houssemFat
Copy link

Same error here using bun

bun --version

1.0.25

Log

$ nuxt dev

Nuxt 3.10.0 with Nitro 2.8.1                                                                                                                                   9:41:58 PM
                                                                                                                                                               9:41:58 PM
  ➜ Local:    http://localhost:3000/
  ➜ Network:  use --host to expose

  ➜ DevTools: press Shift + Option + D in the browser (v1.0.6)                                                                                                 9:41:59 PM


 ERROR  Pre-transform error: Element is missing end tag.                                                                                                       9:42:00 PM


 ERROR  Pre-transform error: Illegal tag name. Use '&lt;' to print '<'.                                                                                        9:42:00 PM

ℹ Vite client warmed up in 413ms                                                                                                                              9:42:00 PM
ℹ Vite server warmed up in 466ms                                                                                                                              9:42:00 PM
✔ Nitro built in 338 ms                                                                                                                                 nitro 9:42:00 PM


Borwser :

image

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

No branches or pull requests

6 participants