currently it only looks at the hovered token, which is fine for simple things, but for indexing in particular it gives no information at all
i.e.
local record Foo
x: number
record Bar
y: string
end
end
hovering on Foo will show the definition
but for hovering something like Foo.Bar will not show any info (except for when you hover over the Foo, but whatever)
To implement this without reimplementing the parser, we either need changes in the teal api to expose more info about nodes or bring in something like tree-sitter. While tree-sitter is nice, I'd like to avoid external deps when possible, especially one that can require some extra steps to install like tree-sitter.
currently it only looks at the hovered token, which is fine for simple things, but for indexing in particular it gives no information at all i.e.
hovering on
Foo
will show the definitionbut for hovering something like
Foo.Bar
will not show any info (except for when you hover over theFoo
, but whatever)To implement this without reimplementing the parser, we either need changes in the teal api to expose more info about nodes or bring in something like tree-sitter. While tree-sitter is nice, I'd like to avoid external deps when possible, especially one that can require some extra steps to install like tree-sitter.