As I read more code than I write, code consistenty and readability are really important for me. That is why I like the .editorconfig and one of the reasons why I blogged about it before:
- Introducing .editorconfig: https://bartwullems.blogspot.com/2017/04/visual-studio-2017editorconfig.html
- Generate an .editorconfig: https://bartwullems.blogspot.com/2019/10/visual-studiogenerate-editorconfig-file.html
- The ‘dotnet format’ command: https://bartwullems.blogspot.com/2020/04/dotnet-format.html
- Let private fields start with an underscore: https://bartwullems.blogspot.com/2019/12/editorconfig-let-private-fields-start.html
- Code cleanup in Visual Studio: https://bartwullems.blogspot.com/2019/10/visual-studio-2019code-cleanup.html
Although I really like EditorConfig files, configuring them is not that easy. If you agree then I have great news for you! Starting from Visual Studio 16.10 an EditorConfig designer was added that allows you to easily view and configure your code analysis preferences.
- Check that you have at least version 16.10 of Visual Studio
- Open the solution containing the editorconfig file
- Click on the .editorconfig file. The designer is loaded:
- The great thing is that if you are looking for a specific setting, you no longer have to open up the documentation but that you can easily search using the provided UI.
Remark: If you still want to edit the file directly in the text view, you still can by pressing F7.