'Visual Studio 2022 quick action from constructor parameter to auto field creation not adding space
In VS 2022, when I press Ctrl + . on a constructor parameter and select "Create and assign field/property", the resulting code is missing spaces around the assignment operator = like this:
_logger=logger
It's not a big deal obviously but annoying to fix manually for unified formatting (defeats the purpose of quick action). Is there a setting somewhere that can fix this?
Solution 1:[1]
You can reset your Visual Studio settings:
Tools => Import and Export Settings => Reset all settings
This will reset all your settings (you can create a backup in the process). After the reset, spaces will be back to normal.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | devax |