Solution 1 :

If “Format Document” is what you are referring to, you just have to press F1 and search for Format Document or just press Shift + Alt + F

Problem :

I have installed the prettier extension on VS Code and use this shortcut – Ctrl+shift+ I. But it doesn’t work for me.

Also tried this- Setting the VSCode preference html.format.wrapAttributes to force. But nothing happens.


Comment posted by Rudrakshi

I mean formatting of code like proper indentations by selecting the code lines using shortcut commands.

Comment posted by Benja Oliva

Shift + Alt + F is the shortcut to format a html document at least on VS Code Windows version. It does the indent to your entire code just by using this option

Comment posted by Rudrakshi

Yes, I tried this but it is not working for VS Code on Ubuntu.