Skip to content

Conversation

@kumarpit
Copy link
Contributor

@kumarpit kumarpit commented Oct 24, 2025

Closes #359

Add schema, indexes, and foreign key constraints information when hovering an association table.

Demo (VSCode)

ruby-lsp-assoc-schema-demo-vscode.mov

@kumarpit kumarpit marked this pull request as ready for review October 25, 2025 23:17
@kumarpit kumarpit requested a review from a team as a code owner October 25, 2025 23:17
vinistock
vinistock previously approved these changes Nov 11, 2025
Copy link
Member

@vinistock vinistock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the contribution!

@vinistock vinistock added the enhancement New feature or request label Nov 11, 2025
@vinistock vinistock dismissed their stale review November 11, 2025 21:16

Didn't notice something


return unless result

generate_column_content(result[:name])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding this as is here works, but it means that any hover on associations needs two round trips to the server to pull information.

Instead of doing that, could we include the required information as part of the association_target response and then extract what's needed to generate the hover?

That way we get all of the data in a single request.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, thats a good point! I'll look into that and let you know, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reveal schema when hovering on an association

2 participants