Code Formatting with Prettier in Visual Studio Code

Published: 26 January 2022
on channel: coDevelop
408
11

Code Formatting with Prettier in Visual Studio Code

Steps to enable auto-formatting on save :

Step1 : Open Preferences, select settings then search "format", make sure enable format on save is "ticked"

Step 2: Install "Prettier" extension by going on to preferences, select extensions

Step 3: Go to default formatter and copy the first line - "editor.default Formatter" : "esbenp.prettier-vscode"

Step 4 : Paste the copied code in setting.json at the end. Make sure to put a comma at the end


On this page of the site you can watch the video online Code Formatting with Prettier in Visual Studio Code with a duration of 16 minute 40 second in good quality, which was uploaded by the user coDevelop 26 January 2022, share the link with friends and acquaintances, this video has already been watched 408 times on youtube and it was liked by 11 viewers. Enjoy your viewing!