While working on Rails projects I have learned to break old habits:
- Don't inherit from a class simply to extend it.
- Don't write a wrapper class to extend an existing class.
- Extend a project class using "include" to include a module.
- Extend Ruby's classes (careful!) the same way.
- Or - extend an existing class by declaring it and adding additional methods.
- In some scenarios, extend an object rather than a class.