https://github.com/robrix/many-types-make-light-work
Don’t subclass.
https://github.com/robrix/many-types-make-light-work
Last synced: about 1 year ago
JSON representation
Don’t subclass.
- Host: GitHub
- URL: https://github.com/robrix/many-types-make-light-work
- Owner: robrix
- Created: 2014-10-11T15:20:00.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2015-04-11T01:04:29.000Z (about 11 years ago)
- Last Synced: 2025-02-05T02:39:14.605Z (over 1 year ago)
- Homepage:
- Size: 11.7 MB
- Stars: 35
- Watchers: 21
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Many Types Make Light Work
This is the talk which I gave at [NSScotland 2014](http://2014.nsscotland.com) in Edinburgh on October 26, 2014. I will be giving it at [NSNorth 2015](http://nsnorth.ca), April 10-12, 2015.
The talk is written in [Deckset-flavoured Markdown](https://github.com/robrix/Many-Types-Make-Light-Work/blob/master/Many%20Types%20Make%20Light%20Work.md).
A [recording of my presentation of v1.0 of this talk at NSScotland](http://vimeo.com/album/3132071/video/111942573) is available.
## Synopsis (for the conf)
Every programmer regularly faces the challenges of managing complexity and change. Subclassing can help us simplify, by sharing code and interfaces between related parts of our program. But when requirements change out from under our class hierarchy, unanticipated fragility can mean bugs, sweat and tears. Swift offers us a better way.
## TL;DR
Subclassing is a broken idea, so factor & compose instead where possible, and when Cocoa makes you subclass, do it in a factored, composable way.