Maintainability debt gets expensive when work runs through it. Match code churn against the roadmap to decide what to refactor and what to leave alone.
I had a senior in my last Ruby job who told me to keep metaprogramming to the minimum and after learning more about design and architecture I’m so glad he taught me that mindset lol. Metaprogramming is very tempting when you have a lot of repeated code that could be drastically reduced, but the whole team needs to be able to understand and work on it too, and not everyone is familiar with these features, nor should they.
I had a senior in my last Ruby job who told me to keep metaprogramming to the minimum and after learning more about design and architecture I’m so glad he taught me that mindset lol. Metaprogramming is very tempting when you have a lot of repeated code that could be drastically reduced, but the whole team needs to be able to understand and work on it too, and not everyone is familiar with these features, nor should they.
It’s soooo tempting in Ruby. You can be so clever in it. But yes, it’s a trap.