-
Notifications
You must be signed in to change notification settings - Fork 2
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
Support creating T::Enum
from Rails enum
s
#3
Comments
Hey @coreyja , Very sorry to have missed this!
Yes, correct!
Yep, this is the very much so in-line with the spirit of the repository. If you submit a compiler for this, we'd happily accept it. |
HI @coreyja - I looked into sorbet-rail's support for this. It works through the combination of an AR monkey patch and a compiler, so it's a little nasty. It would be preferable if we could figure out a way to make this modular so that consumers of Boba could opt in (out by default). I still think there's a place for this here. I would just like to keep things modular if possible. Side note: We don't use AR |
Thanks for looking into the sorbet-rails repo and getting back to me! Definitely makes sense to want to keep it modular and disabled by default. Will definitely keep that in mind if/when we start coding something up! Also thanks for mentioning No specific plans or timelines for getting an implementation of this put together, but will definitely let you know as we have plans related to it. Whether that means doing something internal at first, or 'straight' to boba, still TBD. |
Hello!
Found this gem from the Tapioca Readme, about a place for DSL Compilers that didn't fit in Tapioca directly
I also believe that this gem has some Runtime support as well, which is something I don't believe
tapioca
supports at all.I'm coming from using
sorbet-rails
and one thing that is looking to be painful in migrating is that we are heavily using their Runtime support for creatingT::Enum
classes from Railsenum
s (https://github.com/chanzuckerberg/sorbet-rails#typed_enum-instead-of-enum) [We don't usetyped_enum
but I couldn't find a better place in the Readme to link]I'm curious if a compiler and support for this is something you might accept in this project?
We will likely write something in-house, but would be more than happy to contribute it back assuming is something others might find valuable!
No problem if not, but wanted to open an issue before we started working on it internally, so we could have a roadmap for the future of the compiler I imagine we will write sometime soon-(ish)!
Edit: Actually not sure if its just runtime code, or if we will need a DSL compiler as well. But I think my original question of it boba might want to support this still stands!
The text was updated successfully, but these errors were encountered: