Skip to content

Instantly share code, notes, and snippets.

@coreyfloyd
Last active December 17, 2015 03:18
Show Gist options
  • Save coreyfloyd/5542224 to your computer and use it in GitHub Desktop.
Save coreyfloyd/5542224 to your computer and use it in GitHub Desktop.
Model Objects should be dumb - minimal logic
Model Controllers should perform model manipulations that are UI independent (like network and processing) exception: user input
No Story Boards
Implement classes with dependency injection - favor providing all data at instantiation
Code for iOS 6 - will back port to iOS 5 as necessary
When creating “updateUI” methods, pass an animated flag: ex. updateUIanimated:(BOOL)animated;
Constants should be defined in the file that uses them if possible (i.e. Notification constants should be defined in the header of the file that posts the notification)
When a notification is required, evaluate potential patterns in this order, selecting the highest rated viable pattern:
1. Blocks
2. Notification Center
3. Delegation
4. ReactiveCocoa
4. KVO (MAKVONotificationCenter)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment