nvim_runtime_lua

lsp.CodeLens

A code lens represents a {@link Command command} that should be shown along with source text, like the number of references, a way to run tests, etc.

A code lens is unresolved when no command is associated to it. For performance reasons the creation of a code lens and resolving should be done in two stages.

Fields3

CodeLens.range : lsp.Range

The range in which this code lens is valid. Should only span a single line.

CodeLens.command : lsp.Command | nil

The command this code lens represents.

CodeLens.data : lsp.LSPAny | nil

A data entry field that is preserved on a code lens item between a {@link CodeLensRequest} and a {@link CodeLensResolveRequest}