You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey, welcome. So I assume by saying "full", you mean that the existing completionContext isn't enough? It certainly doesn't contain the lines of code previous to the location at which the cursor triggered the completion.
So getting more context about the current buffer is actually something that's shown in our quickstart in the README. We have things like this:
document=server.workspace.get_document(params.text_document.uri)
# `params.position` is the current cursor positioncurrent_line=document.lines[params.position.line].strip()
Does that give you some inspiration for exploring getting more context?
Hi, I'm working on an LSP Server and right now I'm implementing the Completations.
I wanted to ask how to read the full context (like the actual line of code or the lines of code previous to the current buffer) from
CompletionParams
.Thanks.
The text was updated successfully, but these errors were encountered: