Skip to content
This repository was archived by the owner on Apr 6, 2023. It is now read-only.
/frameworkPublic archive

fix(nuxt): remove literal <script setup> from comment - #6331

Merged
pi0 merged 1 commit into
mainfrom
fix/compiler-hiccup
Aug 3, 2022
Merged

fix(nuxt): remove literal <script setup> from comment#6331
pi0 merged 1 commit into
mainfrom
fix/compiler-hiccup

Conversation

@danielroe

Copy link
Copy Markdown
Member

🔗 Linked issue

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

Seems there's a compiler bug (which I will look into) giving this error when using client-only. This PR is a hotfix.

 ERROR [@vue/compiler-sfc] Missing semicolon. (1:10) 12:30:39
anonymous.vue
22 | const { setup, render: _render, template: _template } = component
23 | if (_render) {
24 | // override the component render (non <script setup> component)
| ^
25 | component.render = (ctx, ...args) => {
26 | return ctx.mounted$
anonymous.vue
22 | const { setup, render: _render, template: _template } = component
23 | if (_render) {
24 | // override the component render (non <script setup> component)
| ^
25 | component.render = (ctx, ...args) => {
26 | return ctx.mounted$
at instantiate (node_modules/@babel/parser/lib/index.js:72:32)
at constructor (node_modules/@babel/parser/lib/index.js:359:12)
at Object.raise (node_modules/@babel/parser/lib/index.js:3339:19)
at Object.semicolon (node_modules/@babel/parser/lib/index.js:4000:10)
at Object.parseExpressionStatement (node_modules/@babel/parser/lib/index.js:15244:10)

📝 Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify

netlifyBot commented Aug 3, 2022

Copy link
Copy Markdown

Deploy Preview for nuxt3-docs canceled.

NameLink
🔨 Latest commita558f0e
🔍 Latest deploy loghttps://app.netlify.com/sites/nuxt3-docs/deploys/62ea5d130af0a20008be1a64

@danielroedanielroe self-assigned this Aug 3, 2022
@danielroe
danielroe requested a review from pi0August 3, 2022 11:34
@pi0

pi0 commented Aug 3, 2022

Copy link
Copy Markdown
Member

Could it be related to one of our internal transforms?

@atinux

Copy link
Copy Markdown
Member

Approved as a hotfix (cannot run docus theme locally now), I let you find the root cause 🍀

@danielroe

Copy link
Copy Markdown
MemberAuthor

Yes, I'm looking into root cause. 👍

@pi0
pi0 merged commit fbe2459 into mainAug 3, 2022
@pi0
pi0 deleted the fix/compiler-hiccup branch August 3, 2022 11:49
@danielroe

Copy link
Copy Markdown
MemberAuthor

~> nuxt-content/nuxt-component-meta#35

@pi0

pi0 commented Aug 3, 2022

Copy link
Copy Markdown
Member

@danielroe Does it mean Nuxt and Vite defaults are safe?

@danielroe

Copy link
Copy Markdown
MemberAuthor

No problem with Nuxt. It was a wrong usage of the SFC parser.

@pi0pi0 mentioned this pull request Aug 5, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@danielroe@pi0@atinux