Delete this tag/brace and its matching tag/brace
1 <div className="a">
2 <div className="b">
3 </div>
4 <div>
I am on line 1, I want to delete the div tag in line 1 and the matching tag at line 4, what keys do I need to hit?
Please sign in to leave a comment.
Code | Unwrap/Remove...
Not sure i follow you... what problems matching/deleting braces have you faced?
delete div tag at line 1 and its enclosing tag on line 4
not working for react jsx
Please follow https://youtrack.jetbrains.com/issue/WEB-30064 for updates
Andriy Bazanov's answer, Code | Unwrap/Remove..., is correct
How do I find this Code | Unwrap/Remove..., ? I don't have it. v 2022.3
The action is there, in Code main menu, just as before
Elena Pogorelova I see I guess I have confused this feature and its functionality with something else. This option appears not everywhere.
I thought with its help I could delete for example line 8 (an opening code block ) and ..586 (the closing curly bracket) in SCSS for removing unneeded indentation. But this `unwrap` is something different and doesn't work in SCSS files. Not what I was looking for.
There is no such feature for SCSS; if you miss it, please vote for https://youtrack.jetbrains.com/issue/WEB-35406/Add-support-for-the-unwrap-command-in-SCSS-files