Visual Studio 2019 Tricks and Techniques: A developer’s guide to writing better code and maximizing productivity
- Length: 386 pages
- Edition: 1
- Language: English
- Publisher: Packt Publishing
- Publication Date: 2021-01-15
- ISBN-10: 1800203527
- ISBN-13: 9781800203525
- Sales Rank: #2119026 (See Top 100 Books)
Harness the full power of the Visual Studio IDE to take your coding skills to the next level by learning about IDE productivity practices and exclusive techniques
Key Features
- Increase your productivity by leveraging Visual Studio 2019’s improvements and features
- Explore powerful editing, code intelligence, and source code control features to increase productivity
- Delve into VS’s powerful, untapped features such as custom project templates and extensions
Book Description
Visual Studio 2019 (VS 2019) and Visual Studio Code (VS Code) are powerful professional development tools that help you to develop applications for any platform with ease. Whether you want to create web, mobile, or desktop applications, Microsoft Visual Studio is your one-stop solution. This book demonstrates some of the most sophisticated capabilities of the tooling and shows you how to use the integrated development environment (IDE) more efficiently to be more productive.
You’ll begin by gradually building on concepts, starting with the basics. The introductory chapters cover shortcuts, snippets, and numerous optimization tricks, along with debugging techniques, source control integration, and other important IDE features that will help you make your time more productive. With that groundwork in place, more advanced concepts such as the inner workings of project and item templates are covered. You will also learn how to write quality, secure code more efficiently as well as discover how certain Visual Studio features work ‘under the hood’.
By the end of this Visual Studio book, you’ll have learned how to write more secure code faster than ever using your knowledge of the extensions and processes that make developing successful solutions more enjoyable and repeatable.
What you will learn
- Understand the similarities and differences between VS 2019 and VS Code
- Get to grips with numerous keyboard shortcuts to improve efficiency
- Discover IDE tips and tricks that make it easier to write code
- Experiment with code snippets that make it easier to write repeating code patterns
- Find out how to customize project and item templates with the help of hands-on exercises
- Use Visual Studio extensions for ease and improved productivity
- Delve into Visual Studio’s behind the scene operations
Who this book is for
This book is for C# and .NET developers who want to become more efficient and take advantage of features they may not be aware of in the IDE. Those looking to increase their productivity and write quality code more quickly by fully utilizing the power of the Visual Studio IDE will also find this book useful.
Table of Contents
- Flavors of Visual Studio
- Keyboard Shortcuts
- IDE Tips and Tricks
- Working with a Repository
- Working with Snippets
- Database Explorers
- Compiling, Debugging, and Version Control
- Introduction to Project and Item Templates
- Creating Your Own Template
- Deploying Custom Templates
- Overviewing VS 2019 Extensions
- Overviewing VS Code Extensions
- CodeMaid is Your Friend
- Be Your Team’s Hero with CodeGenHero
- Secure Code with Puma Scan
- Appendix – Other Popular Productivity Extensions
Visual Studio 2019 Tricks and Techniques Why subscribe? Foreword Contributors About the authors About the reviewers Packt is searching for authors like you Preface Who this book is for What this book covers To get the most out of this book Download the example code files Code in Action Download the color images Conventions used Get in touch Reviews Section 1: Visual Studio IDE Productivity Essentials Chapter 1: Flavors of Visual Studio Technical requirements Quick reference cheat sheet Visual Studio 2019 (Windows) Features of VS 2019 Enterprise edition Visual Studio 2019 for Mac GitHub Codespaces Summary Chapter 2: Keyboard Shortcuts Technical requirements Windows shortcuts Shortcuts that work in both Windows and Visual Studio Intermediate-level shortcuts Keyboard mapping schemes Choosing a keyboard mapping scheme Customizing your own keyboard mapping schemes Creating an individual shortcut Viewing existing shortcuts Importing an entire keyboard mapping scheme Learning keyboard shortcuts Installing the Learn the Shortcut extension Default Learn the Shortcut behavior Justification for investing time Summary Further reading Chapter 3: IDE Tips and Tricks Technical requirements Having fun with the file tabs Pinning documents Vertical documents Horizontal and vertical groups Traversing your solution Navigating through active windows or tabs Using Quick Launch Track Active Item Live sharing Preview Features Faster editing Column Mode Multi-caret selects Toolbox Cleaner code Code Formatting Code Cleanup Summary Chapter 4: Working with a Repository Technical requirements Automating Git commands Git commands quick reference Working with source control Creating a repository For Windows For VS Code For Mac Cloning a repository For Windows For VS Code For Mac Getting updates (Fetch and Pull) For Windows For VS Code For Mac Adding files For Windows For VS Code For Mac Creating a .gitignore file Committing (and pushing) your code For Windows For VS Code For Mac Stashing (and applying) your code Understanding branch and merge Creating a branch Working with pull requests Summary Chapter 5: Working with Snippets Technical requirements Snippet basics Inserting snippets Code Snippets Manager dialog Examining a custom snippet's XML definition Deploying snippets Importing a custom snippet Summary Further reading Chapter 6: Database Explorers Technical requirements Managing databases in Visual Studio 2019 for Windows Working with SQL Server Object Explorer Interacting with databases in VS Code Getting connected Creating our database Expanding the database Summary Chapter 7: Compiling, Debugging, and Versioning Technical requirements Installing Docker Exploring compilation flags and options Visual Studio 2019 for Windows Visual Studio Code Visual Studio 2019 for Mac Conditional compilation Regions Pre-build and post-build events Investigating advanced debugging Breakpoints The Immediate window Who's watching? Remote debugging Remote debugging Docker in Visual Studio 2019 for Windows What about remote debugging in VS Code? Visual Studio 2019 for Mac, too! Discovering versioning Versioning in traditional full framework .NET projects Versioning in .NET Core Summary Section 2: Customizing Project Templates and Beyond Chapter 8: Introduction to Project and Item Templates Technical requirements Understanding item templates Knowing when to use project templates Template tags When to use templates Looking at a sample scenario Running the project Examining the project Valuing templates Summary Further reading Chapter 9: Creating Your Own Templates Technical requirements Exporting a custom project template Using the exported project template Identifying issues with the project template Fixing problems in the template definition Understanding template parameters Reimporting the fixed template Exporting project items Summary Chapter 10: Deploying Custom Templates Technical requirements Installing the Visual Studio SDK component Introducing the client-server project Client-server sample code Creating the VSIX deployment package Reviewing the deployment project Examining the template project Making template wizards Using the VSIX deployment package Testing the project template Publishing to the Visual Studio Marketplace Distributing instructions for the Dotnet Core CLI Summary Section 3: Leveraging Extensions for the Win Chapter 11: Overviewing Visual Studio 2019 Extensions Technical requirements What are extensions? Visual Studio Marketplace Creating extensions Creating extensions in Visual Studio 2019 for Windows Creating extensions in Visual Studio 2019 for Mac Roslyn analyzers Summary Chapter 12: Overviewing VS Code Extensions Technical requirements What are VS Code extensions? VS Code in the Visual Studio Marketplace Creating an extension Generating a basic extension Making our extension work for us! Publishing your extension Summary Chapter 13: CodeMaid is Your Friend Technical requirements A brief history of CodeMaid Configuring CodeMaid Reorganizing to reduce merge conflicts User profile and solution settings Learning about cleanup actions The narrowing gap Exploring CodeMaid Spade McCabe Cyclomatic Complexity Build Progress Summary Chapter 14: Be Your Team's Hero with CodeGenHero Technical requirements Understanding the core concepts of code generation Metadata and templates Introducing CodeGenHero™ Installing CodeGenHero™ Example project overview Scaffolding a solution – .NET Core CLI The CodeGenHero™ solution Creating a metadata source Configuring a blueprint Choosing templates Configuring template parameters Mapping target projects Integrating generated code Handling change with CodeGenHero™ How does it work? Changing the database schema Merging changes Summary Chapter 15: Secure Code with Puma Scan Technical requirements Understanding common application security vulnerabilities A1:2017-Injection A6:2017-Security Misconfiguration A7:2017-Cross-Site Scripting (XSS) A9:2017-Using Components with Known Vulnerabilities A10:2017-Insufficient Logging and Monitoring Finding vulnerabilities for fun and profit Automating vulnerability detection with Puma Scan Installing Puma Scan in Visual Studio 2019 Installing Puma Scan in VS Code Running Puma Scan and viewing the results Extending Puma Scan with custom sinks Using Puma Scan in a DevSecOps pipeline Summary Appendix Other Popular Productivity Extensions Presenting some great Visual Studio 2019 for Windows extensions Conveyor by Keyoti Ozcode – Magical C# debugging Open Command Line ReSharper Visual Studio Spell Checker Sharing our favorite Visual Studio Code extensions Increment selection CamelCase C# extensions The vscode-icons and vscode-icons-mac extensions Beautify The vscode-spotify extension Choosing useful Visual Studio 2019 for Mac extensions LiveXAML for Xamarin.Forms MFractor NuGet package management extensions MvvmCross Template Pack Summary Other Books You May Enjoy Leave a review - let other readers know what you think
Donate to keep this site alive
How to download source code?
1. Go to: https://github.com/PacktPublishing
2. In the Find a repository… box, search the book title: Visual Studio 2019 Tricks and Techniques: A developer’s guide to writing better code and maximizing productivity
, sometime you may not get the results, please search the main title.
3. Click the book title in the search results.
3. Click Code to download.
1. Disable the AdBlock plugin. Otherwise, you may not get any links.
2. Solve the CAPTCHA.
3. Click download link.
4. Lead to download server to download.