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

SFC top level await with single-line if condition is being compiled incorrectly #4596

Closed
dsine-de opened this issue Sep 15, 2021 · 0 comments
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. scope: script-setup

Comments

@dsine-de
Copy link

Version

3.2.11

Reproduction link

sfc.vuejs.org/

Steps to reproduce

Check the JavaScript console output in the reproduction link.

What is expected?

The console.error() should never be executed.

What is actually happening?

The console.error() is being executed when a single-line if statement is used (it works correctly with if statements that have curly brackets).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🔨 p3-minor-bug Priority 3: this fixes a bug, but is an edge case that only affects very specific usage. scope: script-setup
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants