Installation

Prerequisites

Visual Studio Code

C# for Visual Studio Code

.NET 7.0 SDK


Formatter and linter

Change C# default formatter

  1. Install Prettier
  2. Open Visual Studio Code settings

    Screenshot

  3. Then click to "open settings (JSON)"

    Screenshot

  4. Add the formatter config

    {
        "editor.defaultFormatter": "esbenp.prettier-vscode",
        "[csharp]": {
            "editor.defaultFormatter": "ms-dotnettools.csharp"
        }
    }
    
  5. Add the linter config

    {
        "omnisharp.enableRoslynAnalyzers": true,
        "omnisharp.enableEditorConfigSupport": true
    }
    

Format code on save

  1. File
  2. Preferences
  3. Settings
  4. Search for Format On Save and check the box.

It is also possible to format the code manually with a shortcut:

  • On Windows Shift + Alt + F
  • On macOS Shift + Option + F
  • On Linux Ctrl + Shift + I


Start the app

When the repo is cloned, go see README.md to know how properly start the app.

results matching ""

    No results matching ""