๐ What gets our 1700 new users on @KairnApp super excited? "Your macOS task capture is c-r-a-z-y powerful". That's because it's developed in #SwiftLang to stay light and high performance. Let's dig in our Swift master @JulienLacr0ix 3 points to know before jumping in macOS dev๐
When we met @JulienLacr0ix he was a full on iOS developer with +10Y of experience building super cool interactive apps. The challenge on Kairn was to build not just an iOS app but also a macOS app, same #SwiftLang but totally new environment for him.
There are very few macOS developers and most apps you have on your mac are coded in Electron, a very cool framework created by @github to build cross platform desktop app with @JavaScript (the language we use on our web app). But we wanted a native app for peak performance...
So 1 year in, learning all the tricks of coding for #macOS, what are @JulienLacr0ix top 3 tips to start building?
#1 - Testing on macOS environment is not easy because unlike on iPhone, a lot of users do not updated their macOS version so you need to test tons of versions and there's no simulator to do so.
#1...When you release a new update you need to check how it runs on each version. There are huge "breaking" changes between macOS 10 and 11 in the UI, components margins and also the Apple API. Fortunately, between Big Sur (11.X) and Monterey (12.X) changes are less structural ๐
#1...On Kairn, we support versions from 10.14 onwards (that's back from 2018 with Mojave!!) and we still have people who can't use it coz they're on previous macOS versions... Question for macOS apps here, what versions do you support?
#1... So how do you test? Thankfully there's @MacinCloud on which you can handle versions 10.14+ to do your testing. The hard part is that you can't test permission handling so for us, on onboardings we still have do a lot of manual testing with feature flags for the team.
#1... Last, a CI/CD pipeline for macOS is very pricey. The @github action cost of a macOS minute is 10x more expensive than on Linux (that we use for our webapp testing) so when you build your app it gets $$$ to run your tests
#2 - You need to make sure your users update your app - maintaining multiple versions is a n-i-g-h-t-m-a-r-e ๐ป. Unfortunately inciting users to update ain't easy, but in the early days we sometimes have to push breaking changes or fix the app, so we really need everyone updated!
#2... You can force an update on users when they open the app but it's a bit rough, you can push a notification and hope they'll update but then it's a mess, and you can time your notification well + force it at the right moment and that's what we chose!
#2... We use Sparkle, a framework that simplifies updating macOS apps for the end user. After 2 months of using it, we got many users that were not updating their app โI got an update during my deep-work session - I skipped itโ. Not ideal when youโre a doing productivity app ๐
#2... So we added 3 layers - (1) initial push like in the gif above - we call it "soft release", (2) the day after you get a notification if not done, (3) 2 days after the release a mandatory update is done to make so everyone is on the right version โ It's now muuuuch smoother.
#3 There's not a lot of macOS developers so itโs hard to find resources in the community and especially if you want to solve a complex problem. Our solution is to follow great macOS developers and people who find creative ways on the macOS platform!
#3... And to finish, over the last months, @JulienLacr0ix has been teaching #SwiftLang to the rest of our tech team (and learning #Nodejs ๐ค) for peer-coding and review sessions! They're always digging together for solutions inspired by their respective experience ๐ง
That's it on this thread! Can't wait to hear your top tips for building on macOS environment too?
If you'd like to know more feel free to follow our journey on @KairnApp and see how we grow from Product of the Day on @ProductHunt and beyond ๐ฅ meow.ph/kairn