Judicious Use of Shitty Code
Here’s a little secret for newbie app developers out there: a fun app has nothing to do with clean code.
Some of the worst code I’ve ever written has been in my most successful projects. Version 1.0 of Pillboxie was a tangle of spaghetti code written without delegation, NSNotificationCenter, or KVO. Let that sink in. Everything was somebody else’s property. Pillboxie 1.0 was featured at launch and many times thereafter. I haven’t updated that app in years and people still download it and use it.1 Riposte, still used and loved by some App.net diehards, has one or two view controllers I wrote that are thousands of lines long. The app was littered with procedures that should have been generalized but got copied-and-pasted everywhere. And it didn’t matter. If we’d had the time (Riposte was a side project) to write all the code “correctly,” it wouldn’t have made the app any better for the end user.
Not all shitty code is equal. There’s such a thing as judicious use of shitty code. Your app shouldn’t crash, so don’t try to be clever. Don’t assume that a web service will always give you the values you expect. Don’t assume that some index
is within the length of an array
. Don’t pass an NSManagedObject between threads. Some corners shouldn’t be cut.
If your goal is only to learn, then write clean code. But if your goal is to build a successful business, then stop trying to impress your heroes. Learn as you go. Be messy. Don’t use new technologies. Don’t use new languages for their own sake. Don’t waste time trying to think of the most elegant way to break an egg. Just smash it on the counter and leave a FIXME:
comment and move on. The only question that matters: is this app fun or what?
-
Boy, do I really need to update that app sometime. ↩
App Store Search is More Depressing than the Game of Thrones Finale
When I visit Google and search for twitter iphone app
, this is what I see:
When I perform the same search on the App Store for iOS’ search tab, here are the top results:
How is that even — I don’t — Ugh — Only two apps are visible, neither of which are a) Twitter clients or b) made by Twitter or c) even remotely related to Twitter.
The most important store front on the most important mobile device is seven years old and still has the worst search experience I’ve ever used. Search is a commodity service in 2015. There’s no excuse.
How to Become an Indie Developer
- Do you have a day job that pays you a full-time salary? If yes, proceed to Step 2. If not, skip to Step 3.
- Quit your day job.
- Do you have alternate income besides a job with a regular salary? A spouse with a well-paying career? At least forty-thousand dollars in a savings account? Stock options from that old job that IPO-ed last year? If you have any of these things, jump to Step 5. Otherwise, proceed to Step 4.
- You cannot become an indie developer. Ask for your day job back. Do not proceed to Step 5 or 6.
- Open Xcode.
- You are now an indie developer.
Origin of the CMD Symbol
Susan Kare spoke at the Layers conference this past week in San Francisco. During her presentation she showed the origin of the CMD symbol she designed for the original Mac. I had no idea it was so storied.
Here’s the CMD symbol as it looks today:
Through a book of obscure iconography, Susan Kare found this symbol used on Swedish road signs to indicate a landmark:
The Swedish symbol itself was inspired by an ancient castle on the island of Borgolm:
How cool is that?
WWDC 2015
As WWDC’s go 2015 is one of my favorites ever. I know 2014’s is supposed to be everyone’s favorite because of how shocking it was (Swift, extensions, keyboards, Metal, etc.). But what I love about this year’s is how it wasn’t another massive dump of new APIs. Last year felt overwhelming. This year makes me feel empowered to do more:
Swift has been revved to 2.0, and Objective-C frameworks like UIKit have been updated with nullability qualifiers and and parameterized collections. I feel comfortable using Swift in production code for the first time.
Split View multitasking on iPad brings size classes and AutoLayout from the bleeding-edge of UI development into the center of the picture. AutoLayout may not yet be mandatory, but the essential role of size classes and trait collections (in order to support iPad multitasking app size changes) signals that these new(ish) APIs are here to stay.
Swift is going open source! I am thrilled by this news. Imagine how cool it will be to build shared libraries between clients and servers, all backed by Swift’s safety features and written in the same IDE. The only thing I’m not excited about is the inevitable showdown between thirty-eight sloppy open-source ports of Foundation into Swift. Prepare for some Wild West shit.