Pastecard: Locals Only

The Pastecard iOS app does some things that the web app simply cannot do: it hooks into the system-level share sheet, it shows widgets, it works with Siri, and now it can work exclusively on your phone with no web connection whatsoever. This has been on my to-do list for Pastecard for a long time (also on there: built-in URL shortening), as something that makes the iOS app worth buying to people who have no idea what Pastecard is. As I’ve written before, the inspiration for Pastecard as a concept was a mix of the (mini) Hipster PDA and the Simplenote app. The inspiration for Pastecard’s iOS app was first Scratch (RIP) and later Edit.

Both those apps were very well received by the Apple community when they were released, and probably because both were simple and polished versions of that old “do one thing well” chestnut. Scratch even supported sync by way of Dropbox and had a customizable toolbar above the keyboard, while Edit had a few quick actions in its toolbar and nothing else. Neither required an internet connection to write. Owing to both its beginnings as a web app and my lack of native app development experience, I designed the Pastecard iOS app as being dependent on the web. If your device was offline, you could only view your text, because it wouldn’t be able to sync any changes back to your account on the server. That limitation always bothered me, but never to the point where I considered tackling the intricacies of race conditions and graceful degradation involved with that.

Fast forward to now, where I have a stable iOS app that I’m proud of, and some free time to build on its foundation. I thought of a way to designate an account in the iOS app that represents the local device and cannot be overwritten by the sign up process,2 add some conditional logic around each function in the app (first check if logged in at all, if yes check if the username matches the local one, and so on), and modify the swipe-up menu to handle the difference between a regular account and this local account. And that was all it took to get a version of Pastecard that does not care if you have a network connection. Because in this mode, it never talks to the internet, and not only does that make the app feel much faster, it’s also just kinda cool these days.

I liked the way this turned out so much, that now anyone who buys it from the App Store will go straight into this local-only mode the first time they run the app. They still have the option to “sign out” of that account and then sign in with an existing Pastecard account or create a new one, and then the app will sync with the cloud like before. But with this new mode as the default, Pastecard is now a direct competitor to some of these similar apps that have, from all accounts, obtained some measure of success. I don’t think I’ll pursue that anytime soon though.