Collapse JSX tag

Convert an empty JSX tag into a self-closing tag.

Cleanup
P42 for VS Code
P42 for GitHub
Collapse JSX tag

Why is this refactoring helpful?

Unnecessary closing elements (with potential whitespace) are additional text that needs to be read and understood. Self-closing elements make the code more concise.

Related Code Actions

Learn More

Available In