How to use Prettier in VS Code - Code Formatting

preview_player
Показать описание
In this video I will show you how to install and configure Prettier Code Formatter in VS Code. Formatting code consistently can be a challenge, particularly when working on a team. Code formatters like prettier can help solve this issue. Consistent code formatting helps with the readability of a project.

Learn how to setup VS Code to format code whenever a file is saved or code is pasted into VS Code.

Learn how to configure Prettier using a JSON configuration file .prettierrc

Learn the difference between VS Code user settings and VS Code workspace settings.

If you are having trouble getting prettier to work uninstall Prettier Code Formatter extension and follow this video.

Prettier Configuration

Prettier Settings Options

Prettier extension
Рекомендации по теме
Комментарии
Автор

Just what I was looking for to resolve my code formatting issue. Thanks Adam!

soumitralahiri
Автор

Bro thank you very much. I searched for this solution everywhere but I didn't find. This video really helped me. Now my prettier is working.

pubgm
Автор

Although English is not my first language, I found this tutorial so easy to understand thanks to your excellent and clear explanation! Impressed and subscribed 🤗

xjmtrpv
Автор

Amazing video. This has saved me lots of time trying to keep my code neat. Thanks!

erickchavez
Автор

Nice job with explaining bud. Was very easy to understand.

cjcro
Автор

Thank you! Just what I was looking for.

jeffreyhunter
Автор

Yeah dude, this video nailed it, here is a new sub!

elcancion
Автор

wow,
I didn't know that prettier is so nice before watching this video
thanks for the nice video

fighter
Автор

Thanks for the config file and the 'semi' parameter !

achillesus
Автор

Thanks Adam, for to the point explanat. 😀

isatyamshivam
Автор

presh helped me a lot since im just starting to learn and it takes much effort to just press shift lol

Varyeth
Автор

Informative! Thanks for sharing your great experience.

gfxmentoring
Автор

Big thank you, it was very helpful to me 🌼

xecqegs
Автор

Be carful with the format on save. When you format code that you have not changed and commit it to git it can make it hard to tell what the REAL changes for the commit are. Easy to work around this, just run prettier on the whole code base (WITHOUT ANYT OTHER CHANGES) then check it in. Then running the formatter on save will not obfuscate the real changes in your commits.

JohnAshleyMckenzie
Автор

Man, you are the best! thank you for this video !

carlosbracho
Автор

Nice video man make more coding tutorials u rock👑💯

CieloGotCash
Автор

LOVE workspace setting i was stucking on it thank you

entrinsek
Автор

well explained sir. Thank you! Subscribed

ashimghoshfm
Автор

Thank you for this, I was wondering if I was doing something wrong.

quatron
Автор

thanks, this video help me and easy to understand

alkhiddier