Open
Description
Apache NetBeans version
Apache NetBeans 14
What happened
When you have this piece of code:
const test = {
};
and you hit enter after the open bracket, it will auto indent n-spaces depends on the defaults/settings. For me it is 4 spaces. When you now hit ".", the formatting jumps 8 spaces further which is not correct.
const test = {
.
};
How to reproduce
- Open/Create a new JS file inside an HTML5 Project
- Type the example code in
- Go to the new line between the brackets and hit "."
- It will add more spaces than expected. Doesn't matter whether the cursor is on position 0 or on the indentation (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
I also set the JavaScript features to "ESNext" that also didn't work out.
Are you willing to submit a pull request?
No
Code of Conduct
Yes