Files
zed/docs/src/languages/go.md
Marshall Bowers 3220986fc9 Format docs with Prettier (#8134)
This PR formats the docs with Prettier.

Release Notes:

- N/A
2024-02-21 13:21:22 -05:00

1.2 KiB

Go

Inlay Hints

Zed sets the following initialization options for inlay hints:

"hints": {
    "assignVariableTypes": true,
    "compositeLiteralFields": true,
    "compositeLiteralTypes": true,
    "constantValues": true,
    "functionTypeParameters": true,
    "parameterNames": true,
    "rangeVariableTypes": true
}

to make the language server send back inlay hints when Zed has them enabled in the settings.

Use

"lsp": {
    "$LANGUAGE_SERVER_NAME": {
        "initialization_options": {
            "hints": {
                ....
            }
        }
    }
}

to override these settings.

See https://github.com/golang/tools/blob/master/gopls/doc/inlayHints.md for more information.

Go Mod

Go Sum

TODO: https://github.com/zed-industries/zed/pull/7139

Go Work