Emerging Best Practices
summary
Shows concrete Swift 2 techniques and why they matter: demonstrates guard/defer/enum associated values usage, explains dependency injection by swapping a network controller for a protocol-backed stub in unit tests, and gives a working pattern for injectible NSUserDefaults via default parameters. Explains currying for reusable filters, contrasts refactor vs rewrite (changing tests means rewrite), and argues unit tests improve API design. Watch if you want runnable patterns to make Swift code testable and easier to change.
AI-written summary · about
chapters (21)
- 0:00Start
- 2:30Agenda
- 5:32Before Object Literals and ARC
- 5:59After Object Literals
- 7:08Blocks & CCD
- 10:00Swift 2
- 11:11Pyramid of Doom
- 11:38Clause Applause
- 11:57Avoid Mutability
- 13:11Before Currying
- 15:11Extract Associated Values
- 18:22Syntax vs Idea
- 19:01Never Throw Away Ideas
- 20:09Beginner learns thing
- 24:58Things to never throw away
- 25:43Unit Testing & Thinking
- 27:10Benefits of Testing
- 33:04Without Dependency Injection
- 34:39Cheat with Dependency Injection
- 39:56Look for Abstractions
- 44:06Wrap Up








