GoLand 2021.2 Help

Complete paired characters

GoLand can automatically add closing braces and other paired elements.

  1. Press Ctrl+Alt+S to open the IDE settings and select General | Editor | Smart Keys.
  2. Select the Insert pair } checkbox in the Enter group. This enables adding closing braces when you press Enter.

  3. Configure automatic insertion of paired elements by selecting the following check boxes:

    • Insert pair bracket
    • Insert pair quote
    • Auto-close tag on typing '</'
  4. Click OK to apply changes.

The indentation level is defined in the Code Style settings.

Last modified: 19 May 2021