Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Q: What will RBS files bring to IDEs or the API documentation ? #80

Open
DanRathbun opened this issue Aug 15, 2022 · 1 comment
Open
Labels

Comments

@DanRathbun
Copy link
Contributor

Q: What will RBS files bring to IDEs or the API documentation ?

I've noticed your producing RBS definitions for the Ruby APIs.

I'm wondering what will this do the the stubs?

What can it do for IDEs as far as Intellisense, code checking etc.

Will it effect the YARD documentation ?

@thomthom
Copy link
Member

That's what I was trying to figure out. In order to setup an extension with RBS tooling I needed to generate RBS definition for the SU API.

It caught a number of YARD syntax issues that YARD doesn't warn about. On the other hand, RBS syntax and the syntax used by various RBS tools are not consistent and not always on par with YARD, making auto-generation a challenge. Had to resort to patching after the fact for a few things.

From what I've experienced so far, YARD documentation along with Solargraph (or RubyMine's code insight) gives a decent intellisense to the IDEs. But what RBS should open up for is deeper full application analysis. Checking the code paths, whenever that is possible with a dynamic language such as Ruby, and warn about issues that you'd otherwise catch at run-time.

But the RBS tooling still seem to be in early stages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants