Quantcast
Channel: February 2014 – Michael Tsai
Viewing all articles
Browse latest Browse all 52

Avoiding Massive Controllers

$
0
0

Brad Grzesiak (via Mark Bernstein):

Well, to be sure we’re on the same page, allow me propose rules that must be followed in order to adhere to this heuristic:

  • The IBAction macro must not be used in a View Controller
  • The @interface block in a View Controller’s header file must be blank.
  • A View Controller may not implement any extra *Delegate or *DataSource protocols except for observing Model changes.
  • A View Controller may only do work in viewDidLoad (or awakeFromNib), viewDidAppear, viewDidDisappear, and in response to an observed change in the model layer.

Viewing all articles
Browse latest Browse all 52

Trending Articles