Objection is a popular dependency injection library for Objective-C, created by Atomic Object and yours truly. I’m happy to announce that it has expanded its horizons beyond Objective-C and it can now be used in one of my favorite languages — Ruby.
There’s also Motion Objection, a companion library to Objection that can be used in RubyMotion. It has all of the power and speed of Objection plus the declarative affordances that the Ruby language provides.
I’ve provided an example below that illustrates how Objection can be used in RubyMotion along with an equivalent example in Objective-C.
You can learn even more about Motion Objection here. Enjoy!