title: Put the knife down and take a green herb, dude. |
descrip: One feller's views on the state of everyday computer science & its application (and now, OTHER STUFF) who isn't rich enough to shell out for www.myfreakinfirst-andlast-name.com Using 89% of the same design the blog had in 2001. |
FOR ENTERTAINMENT PURPOSES ONLY!!!
Back-up your data and, when you bike, always wear white. As an Amazon Associate, I earn from qualifying purchases. Affiliate links in green. |
|
x
MarkUpDown is the best Markdown editor for professionals on Windows 10. It includes two-pane live preview, in-app uploads to imgur for image hosting, and MultiMarkdown table support. Features you won't find anywhere else include...
You've wasted more than $15 of your time looking for a great Markdown editor. Stop looking. MarkUpDown is the app you're looking for. Learn more or head over to the 'Store now! |
|
Wednesday, March 17, 2021 | |
How do you Prettier on save in Visual Studio 2019? You use Mads Kristensen's extension, JavaScript Prettier. It lets you set it to run on save, which you absolutely must do. It's an 100% godsend. "But Mads' extension only runs Prettier 1.12.1 if another Prettier isn't installed locally in my project!" I hear you say. "That doesn't put in the extra space between function and () in anonymous declarations! I can't use it!" you complain. Well, thanks to your resident hacker (maybe not my best separation of concerns, but it works), that's not a problem any more. Open Tools >>> settings, choose Prettier, type in the version you want to use. Poof. The embedded version is the version you entered and you're Prettier-ing. Why did I bother updating a Prettier extension for Visual Studio? With my current team, I'm the only dev using, um, modern
client-side tooling (mostly VS Code). Most folks are using Visual Studio 2019. That's
fine. I love VS2019 for C# work. I can see how familiarity sometimes
breeds not contempt but content. -Edness. Or something. But we need to use Prettier as a team. The tool's that good. So update it is! You're welcome. ;^) Btw, I really owe Rackis a whiskey of his choice for this one. Being OCD about whitespace myself, I complained at first (okay, I complained like a cat getting a bath) when he told me years ago that I had to use a tool that automatically "corrected" whitespace for me, reformatting the entire file without apology, before I could check in my code. What the heck?! I know how to format code to make it easiest to read and understand. How dare a tool mess with my art?!!? Then, very quickly, I dropped the pretense and became addicted. In a team using Prettier, I never got a file with craptastic whitespace from another coder. And, more important selfishly, I found I never wasted another moment making sure the whitespace for my code was perfect. Get lazy, type some code, hit save, WHAM, competent whitespace is inserted for you. It's instant. It's mindless. It's magical. Anything that makes coding easier and standardizes something subjective in a way that's Not Wrong is a very good thing. You should use it. Now. You can thank me later for the recommendation... and the extension, if you're still a Visual Studio 2019 addict.Labels: devtools, extension, javascript, visual studio posted by ruffin at 3/17/2021 10:43:00 PM |
|
| |
All posts can be accessed here: Just the last year o' posts: |
||||||||||||||||||||||
|