Beautify / Format Java code in Visual Studio Code

佐手、 提交于 2019-12-10 14:57:25

问题


I have tried some proposals on here and here, but none of them works. How do you accomplish it for Java code or is there a way for general? En passant, I've install XML formatter in order that it may work, but not.


回答1:


For proper formatting, you need to install a VSCode extension that provides Java formatting. Try this one from Redhat: https://marketplace.visualstudio.com/items?itemName=redhat.java

After the extension is installed, that standard code format commands / shotcuts should work for Java code.



来源:https://stackoverflow.com/questions/42940091/beautifyformat-java-code-in-visual-studio-code

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!