VS Code documentation on completion not shown

505 views Asked by At

The documentation on completion is not shown in VS Code even if the language server sends the completionItem/resolve with documentation.

screenshot of vscode

[Trace - 3:33:37 PM] Sending request 'completionItem/resolve - (33)'.
Params: {
    "label": "append",
    "detail": "'a list -> 'a list -> 'a list",
    "insertTextFormat": 1,
    "textEdit": {
        "newText": "append",
        "range": {
            "start": {
                "line": 10,
                "character": 5
            },
            "end": {
                "line": 10,
                "character": 5
            }
        }
    },
    "kind": 12,
    "sortText": "0003",
    "data": {
        "textDocument": {
            "uri": "file:///Users/ulugbekna/codef/scratch-ocaml/gadt.mli"
        },
        "position": {
            "line": 10,
            "character": 5
        }
    },
    "deprecated": false
}


[Trace - 3:33:37 PM] Received response 'completionItem/resolve - (33)' in 3ms.
Result: {
    "label": "append",
    "kind": 12,
    "detail": "'a list -> 'a list -> 'a list",
    "documentation": {
        "kind": "markdown",
        "value": "Concatenate two lists. Same as the infix operator `@`.\nNot tail-recursive \\(length of the first argument\\)."
    },
    "deprecated": false,
    "sortText": "0003",
    "insertTextFormat": 1,
    "textEdit": {
        "range": {
            "start": {
                "line": 10,
                "character": 5
            },
            "end": {
                "line": 10,
                "character": 5
            }
        },
        "newText": "append"
    }
}

The screenshot is from an OCaml file. I'm using OCaml Platform extension and ocamllsp language server.

0

There are 0 answers