Hands-On Visual Studio 2022

Book description

Learn to design, develop, debug, and deploy technologies by harnessing the full power of Visual Studio 2022 by discovering its new features and exclusive techniques

Key Features

  • Discover solutions to common problems faced while using Visual Studio 2022
  • Explore tips, tricks, and best practices and discover ways to overcome source-code challenges
  • Deep dive into Visual Studio’s new features and unleash its potential to enhance your coding journey

Book Description

Visual Studio 2022 is the complete and ideal integrated development environment (IDE) for creating large, complex, and scalable applications. It is one of the most complete tools available for development, especially with Microsoft technologies.

This book will teach you how to take advantage of the tools available with this IDE to write clean code faster. You’ll begin by learning how to set up and start Visual Studio 2022 and how to use all the tools provided by this IDE. You will then explore key combinations, tips, and additional utilities that can help you to code faster and review your code constantly. Next, you will see how to compile, debug, and inspect your project to analyze its current behavior using Visual Studio. The book also shows you how to insert reusable blocks of code writing simple statements. Later, you will learn about visual aids and artificial intelligence that will help you improve productivity and understand what is going on in the project.

By the end of this book, you will be able to set up your development environment using Visual Studio 2022, personalize the tools and layout, and use shortcuts and extensions to improve your productivity.

What you will learn

  • Understand what s new in Visual Studio 2022
  • Discover the various code tools to improve productivity
  • Explore the benefits of using .NET 6 in Visual Studio 2022
  • Perform compilation, debugging, and version control comfortably
  • Become well-versed with various shortcuts, tricks, tips, and tools to improve productivity within Visual Studio 2022
  • Implement remote and collaborative work with Visual Studio 2022

Who this book is for

This book is for .NET software developers focusing on web development and web developers who want to learn about the new features, tools, and features available in Visual Studio 2022. Basic knowledge of HTML, CSS, and JavaScript or frameworks such as React and Angular is assumed.

Table of contents

  1. Hands-On Visual Studio 2022
  2. Contributors
  3. About the authors
  4. About the reviewer
  5. Preface
    1. Who this book is for
    2. What this book covers
    3. To get the most out of this book
    4. Download the example code files
    5. Download the color images
    6. Conventions used
    7. Get in touch
  6. Part 1: Visual Studio Overview
  7. Chapter 1: Getting Started with Visual Studio 2022
    1. Technical requirements
    2. A brief history of VS
    3. VS flavors
      1. Visual Studio Community
      2. Visual Studio Professional
      3. Visual Studio Enterprise
    4. Installing VS 2022
      1. Getting the installer from the website
      2. Installation process
    5. VS for Mac
    6. Summary
  8. Chapter 2: Configuring the IDE
    1. Technical requirements
    2. Synchronizing accounts and settings
    3. Configuring the color scheme
      1. Visual Studio default Themes
      2. Visual Studio Marketplace
    4. Customizing fonts
      1. Changing fonts in the IDE
      2. Reference highlighting
      3. Changing fonts in the code editor
    5. Customizing the menu bar and toolbars
      1. Customizing the menu bar
      2. Customizing toolbars
    6. Customizing panels
      1. Adding tools to panels
      2. Panel accommodation
      3. Working with documents
      4. Managing window layouts
    7. Summary
  9. Chapter 3: Improvements in Visual Studio 2022
    1. Technical requirements
    2. 64-bit architecture
    3. New icons and styles
    4. .NET 6 support
    5. Hot Reload
    6. Other improvements
    7. Summary
  10. Chapter 4: Creating Projects and Templates
    1. Technical requirements
    2. Selecting and searching for templates
    3. Templates for .NET Core
    4. Templates for APIs
    5. Templates for .NET Framework
    6. Templates for SPAs
    7. Summary
  11. Chapter 5: Debugging and Compiling Your Projects
    1. Technical requirements
    2. Debugging projects in Visual Studio
      1. Understanding the technical aspects of debugging
      2. Differentiating between debug mode and run mode
      3. Project debugging initialization options
    3. Exploring breakpoints in Visual Studio
      1. Navigating between breakpoints
      2. Conditional breakpoints
      3. Function breakpoints
      4. Data breakpoints
      5. Dependent breakpoints
      6. Temporary breakpoints
    4. Inspection tools for debugging
      1. Watch window
      2. QuickWatch
      3. The Autos and Locals windows
      4. Call stacks
      5. Immediate window
    5. Summary
  12. Part 2: Tools and Productivity
  13. Chapter 6: Adding Code Snippets
    1. Technical requirements
    2. What are code snippets?
    3. Creating code snippets
    4. Deleting code snippets
    5. Importing code snippets
    6. Summary
  14. Chapter 7: Coding Efficiently with AI and Code Views
    1. Technical requirements
    2. Understanding CodeLens
      1. Finding references in code
      2. Code maps
    3. Working with code views
      1. Class view
      2. The object browser
    4. Using Visual IntelliCode
      1. Whole line completions
      2. IntelliCode suggestions
    5. Summary
  15. Chapter 8: Web Tools and Hot Reload
    1. Technical requirements
    2. Using scaffolding
    3. Installing JavaScript and CSS libraries
    4. Debugging in JavaScript
    5. Hot Reload
    6. Summary
  16. Chapter 9: Styling and Cleanup Tools
    1. Technical requirements
    2. Woking with CSS styling tools
      1. CSS3 snippets
      2. Hierarchical CSS indentation
      3. Color picker
      4. IntelliSense in style files
      5. Working with images
    3. Cleaning code with code analysis tools
      1. Code quality analysis
      2. Working with code styles
      3. Configuring a code cleanup profile
      4. Executing code cleanup
    4. Summary
  17. Chapter 10: Publishing Projects
    1. Technical requirements
    2. The options to publish a project
    3. Publishing in a folder
    4. Publishing in IIS
    5. Publishing in Microsoft Azure
    6. Summary
  18. Part 3: GitHub Integration and Extensions
  19. Chapter 11: Implementing Git Integration
    1. Technical requirements
    2. Getting started with Git settings
    3. Creating a Git repository
    4. Cloning a Git repository
    5. Fetching, pulling, and pushing Git repositories
      1. Fetching repositories
      2. Pulling repositories
      3. Pushing to repositories
    6. Managing branches
    7. Viewing changes in repositories
    8. Summary
  20. Chapter 12: Sharing Code with Live Share
    1. Technical requirements
    2. Understanding VS Live Share
    3. Using Live Share
    4. Performing live editing
    5. Sharing a terminal with other collaborators
    6. Summary
  21. Chapter 13: Working with Extensions in Visual Studio
    1. Technical requirements
    2. Working with the extensions tool
    3. Searching for and installing extensions
    4. Reviewing Visual Studio Marketplace
    5. Setting up extensions
    6. Creating a new theme as an extension
    7. Summary
  22. Chapter 14: Using Popular Extensions
    1. Technical requirements
    2. Adding HTML Snippet Pack
      1. Downloading and installing HTML Snippet Pack
      2. Using HTML Snippet Pack
    3. Cleaning up code with CodeMaid
      1. Installing CodeMaid in Visual Studio 2022
      2. Using CodeMaid
    4. Compiling web libraries with Web Compiler
      1. Installing Web Compiler
      2. Using Web Compiler
    5. Identifying white spaces with Indent Guides
      1. Installing Indent Guides
    6. Summary
  23. Chapter 15: Learning Keyboard Shortcuts
    1. Technical requirements
    2. Shortcuts for use in source code
      1. Shortcuts for searching and navigating through source code
      2. Shortcuts for editing and refactoring
      3. Shortcuts for debugging and testing
    3. The most common shortcuts for use in the IDE
    4. Creating custom shortcuts
    5. Summary
    6. Why subscribe?
  24. Other Books You May Enjoy
    1. Packt is searching for authors like you

Product information

  • Title: Hands-On Visual Studio 2022
  • Author(s): Miguel Angel Teheran Garcia, Hector Uriel Perez Rojas
  • Release date: June 2022
  • Publisher(s): Packt Publishing
  • ISBN: 9781801810548