Feature Request: Add prettify/beautify to function nodes

While it is technically doable to hook something like JS-Beautify into the underlying ACE editor, I think there is a greater picture to consider.

Code formatting is a very diverse topic, everyone has a different view of how the code should be formatted.
Also, it's another library that has to be integrated, kept up-to-date and increases the download size of the editor UI.

From my experience, I have managed without that, because ACE is quite clever regarding auto-indentation and other little helpers. That only helps when typing code directly in the editor area, of course, not when you copy/paste from somewhere else. Occasionally, I copy/paste badly formatted code into VScode.

There has also been some work of integrating the Monaco editor instead of ACE. It's the editor used by VScode.

1 Like