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

feat(compiler): recover parser from incomplete open tag #2867

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

znck
Copy link
Member

@znck znck commented Dec 23, 2020

<div>
  <div |
</div>

and

<div |
<div></div>

are the most common error state when editing <template>. This PR processes these partial/incomplete tags as self-closing elements. Parsing these tags as elements is important as node type is used in VueDX to provide completion.

@znck znck requested a review from yyx990803 December 23, 2020 04:29
@skirtles-code
Copy link
Contributor

@znck. Do you think this is still worth pursuing?

The file compiler-core/src/parse.ts no longer exists since the parser was rewritten, so it isn't clear to me how this change would be applied to the latest code on main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. wait changes
Projects
Status: Needs Review
Development

Successfully merging this pull request may close these issues.

5 participants