The route and view template information for controller actions is currently only available via textDocument/codeLens. Unfortunately claude code's LSP support doesn't the textDocument/codeLens method. This is likely because "code lens represents a command that should be shown along with source text" and CC is just using LSP to get richer data about the codebase with no intention of showing this enriched data to the user.
This is a total bummer because the data is already available through ruby-lsp-rails.
Contrast this to other elements that are accessible through non-codeLens LSP methods:
- Hovering over an ActiveRecord constant shows the full table schema
- Hovering over an association symbol shows the target model's schema
- Go-to-definition on a
_path/_url route helper jumps to the route definition in config/routes.rb
Would it be possible to also expose route and view info for controller actions through another LSP method (hover, definition, or whatever makes sense)?
The route and view template information for controller actions is currently only available via
textDocument/codeLens. Unfortunately claude code's LSP support doesn't the textDocument/codeLens method. This is likely because "code lens represents a command that should be shown along with source text" and CC is just using LSP to get richer data about the codebase with no intention of showing this enriched data to the user.This is a total bummer because the data is already available through ruby-lsp-rails.
Contrast this to other elements that are accessible through non-codeLens LSP methods:
_path/_urlroute helper jumps to the route definition inconfig/routes.rbWould it be possible to also expose route and view info for controller actions through another LSP method (hover, definition, or whatever makes sense)?