7. HELPERS AREN’T AWESOME
• at least for this task
• they share a global namespace
• aren’t a very oo way of solving the problem
• great for shared logic that doesn't relate to the
object. Use sparingly
8. I KNOW MODELS!
• also nope
• All these if conditions relate to the display of data
• Don’t overload your model with that level of
responsibility
9. ENTER PRESENTERS
• Presenters are a simple class with knowledge of
the model and the view.
• Not a stretch to call them a ViewModel
10. PURPOSE
• Presenters help to achieve adherence to SRP
• A Presenter’s purpose is a decorator who has the
job of massaging the decorated object into a ui/
view friendly manner.
11. DECORATOR?
• Taking one object and adding, replacing or
extending its behaviour, whilst allowing access to
the underlying objects methods.
12. PRESENTERS VS DECORATORS
• A decorator isn’t always a presenter, but a
presenter is always likely to be a decorator.
13. END RESULT
• This is more in line with a decorator approach
• We just delegate to the underlying object