redhat-developer / redhat-developer/vscode-xml

Typing '</' does not create the right indentation

Open
#178 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

onTypeFormatting
Dominant language
TypeScript
Stars
328
Forks
101
Avg merge
1d 17h
Merged PRs (30d)
7

Description

Hey,
I noticed that typing </' to automatically create the closing tag does not create the proper indentation.
However, hitting CTRL+Space then selecting End with '</para>' does generate the proper indentation:

<para>
  The variable instructs Ansible to ignore the validation of
  the WinRM certificate as the environment uses self-signed
  certificates.
  </ <-- Generates <para> at the same level as the nested text
<para>
  The variable instructs Ansible to ignore the validation of
  the WinRM certificate as the environment uses self-signed
  certificates.
  CTRL+Space -> End with '</para> <-- Generates '</para> at the same level as the opening tag.

Environment Information
VSCodium

  • Version: 1.37.1
  • Commit: f06011ac164ae4dc8e753a3fe7f9549844d15e35
  • Node.js: 10.11.0

VSCode-XML

  • Version 0.8.0

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the behavior in VSCodium 1.37.1 with VSCode-XML 0.8.0 using the two examples in the issue. Compare typing </ with the CTRL+Space “End with ''” action, and consider the issue done when both produce the closing tag at the opening tag’s indentation level.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.