-
Bug
-
Resolution: Fixed
-
P2: Important
-
Qt Creator 16.0.1, Qt Creator 17.0.0
-
-
10faa44b8 (18.0)
When auto-format on file save is enabled for QML/JS editing, saving a .js file after making changes may distort or break the code formatting.
To reproduce the issue:
- Enable "auto format on file save" from Preferences->Qt Quick->QML/JS Editing.
- Open the attached file with Qt Creator.
- Edit the file and then save.
The original code.
class Foo {
constructor(window) {
}
}
The saved file output:
constructorfunction (window) {}
For Gerrit Dashboard: QTCREATORBUG-33112 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
682466,3 | qmljsreformatter: fix formatting of js class constructor | 18.0 | qt-creator/qt-creator | Status: MERGED | +2 | 0 |