class SyntaxTree::LanguageServer::InlayHints::Hint
This represents a hint that is going to be displayed in the editor.
Attributes
character[R]
label[R]
line[R]
Public Class Methods
new(line:, character:, label:)
click to toggle source
# File lib/syntax_tree/language_server.rb, line 23 def initialize(line:, character:, label:) @line = line @character = character @label = label end
Public Instance Methods
to_json(*opts)
click to toggle source
This is the shape that the LSP expects.
# File lib/syntax_tree/language_server.rb, line 30 def to_json(*opts) { position: { line: line, character: character }, label: label }.to_json(*opts) end