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

Typing / after a < when we know the tag isn't closed should close the open tag. #505

Open
charlespwd opened this issue Sep 27, 2024 · 0 comments

Comments

@charlespwd
Copy link
Contributor

Is your feature request related to a problem? Please describe.
This is a followup of #501 (comment)

It seems like the HTML Language Server also does html/autoInsert when typing / after a <.

Describe the solution you'd like

  • If the user types / after a < and we know that it's safe to close a tag that currently is opened without child, then we should complete it.
  • We shouldn't close tags that are already opened, don't want duplicate close tags (no <div></div></div> pls)

We might be smart and do a "smart edit of the file", pass it through the parser and verify for a LiquidHTMLASTParsing error like we do for the > case.

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

No branches or pull requests

1 participant