Open
Description
Apache NetBeans version
Apache NetBeans 14
What happened
Take this piece of code
const teste = {
tester: {
test: 2
}
};
When you remove the closing bracket on line 4 and delete all spaces and so that the cursor is on line start and hit "}" to readd the closing bracket, it will be added right under the first token letter of test and not on the position where it was expected which is the same indentation column as tester started.
How to reproduce
- Open/Create a new JS file inside an HTML5 Project
- Type the example code in
- Go to the line with the closing bracket after the property test
- Remove the closing bracket
- Remove all spaces and set cursor to the start of the line
- hit "}" to add the closing bracket again
- See that the closing bracket is at the wrong column (please see my little screencast)
Did this work correctly in an earlier version?
No
Operating System
Windows 11
JDK
OpenJDK Runtime Environment 14+36-1461
Apache NetBeans packaging
Apache NetBeans provided installer
Anything else
All that I tested was with a fresh and clean installation of Apache NetBeans 14.
Are you willing to submit a pull request?
No
Code of Conduct
Yes