Hacker News new | past | comments | ask | show | jobs | submit login

I work for one of the companies that partnered with Stripe and have been using Sorbet for ~1 year in prod now (before it was made public).

1. You can migrate class by class or even method by method. 2. You add type support to a method by prefixing it with a special lambda (Sig) that is read at class evaluation. 3. It provides its benefits right away. But really, most value comes from network effects. You won't get type warnings if the method you're calling isnt typed, because the return type cannot then be inferred. 4. No gems are typed right now. We type out type definitions for external dependencies in *.rbi files.

It's funny that you mention typescript because in that sense the two are quite similar. Types are defined either inline or in separate files .rbi/types.d

Opinions in the company are split probably roughly ~60/40 if Sorbet is worth the effort or not with support having a smallish majority.




I also had a similar question as the GP, but more specifically, is it useful for a Rails app? I'm trying to think how much code we actually have that performs "deeper" business-logic, and then it tends to be also used in very specific paths... There isn't a huge amount of that. So is Sorbet helpful for views/controllers/models/presenters as well?


What were the opposing side's concern or argument against it?

Using Rails?


> 1. You can migrate class by class or even method by method.

This is only if you can get it to run on your project. Far as I know, you can't segment it to just a few folders, can you? Our project has tens of thousands of files and even running it all night, it eventually hard crashes.


Does disabling it (using # typed: ignore) for all files but in that folder work? https://sorbet.org/docs/static




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: