java auto import in Visual Studio Code?

倖福魔咒の 提交于 2019-12-03 13:17:39

For organize imports inside a java file

press SHIFT+ ALT + O

The vscode has also the option of enable auto organize imports on save action

A) in order to have everything working just like intellij or eclipse, there is an extension, install it, Ctrl+Shift+P ==> then write create java project.

B) now that you have the project scaffold right, just right click on the editor, choose source action, then organize imports and select the right libraries to be imported.

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