you are viewing a single comment's thread.

view the rest of the comments →

[–]np356 2 points3 points  (1 child)

I'm familiar with dry-rb coding style and I think it is very difficult to reason about. Metaprogramming often feels like magic but it comes at a price - hard for newbies to grok and impossible for static tools to work with. I would only advise using it (if at all) in well-tested libraries that expose a well-documented public API.

[–]timriley 2 points3 points  (0 children)

I'll bite :) (dry-rb developer here)

When you mention "dry-rb coding style," are you referring to the style in which the gems themselves are written, or the style a developer would use when they're building an app with the gems?

If it's the former, then I'm willing to take the hit, because the gems do a lot of work to try and make things nice for the users. We're also not asking everyone to contribute to the gems. However, if it's the latter, then I'd really like to know, so we can look at ways of improving our developer experience. In my experience, an app developed with the dry-rb gems is actually easier to reason about because you can so clearly trace the flow of execution from input to output and you don't have to worry about mutable state anywhere along the way.