-
MapBox
Not today, but sometime it’d be fun to take a look at the sample MapBox iOS app on GitHub.
-
If they release a new feature for the OS, then get that included in your app and submit it for "featured" app status a good few weeks before that new iOS is released.
-
Shaking the Tree
One day, I want to scan through my app's source code, and remove any functions (or anything else) that aren't actually used. The best way I know of to do this is to use Periphery. There are likely others, but this seems like a good, robust, actively…
-
Biscuits
I found some biscuits that I didn't know I had. They are yum. Winning.
-
Today and Tomorrow
I’m going to want to label my map pins as Today and Tomorrow where appropriate, then Sunday, Monday etc for the remaining days. To do that, I’ll want to look at this post.
-
Smooth As
I really want to try AnyLayout to make the VStack to HStack transition butter-smooth.
-
Make two things the same size
To make two (or more) objects the same height in SwiftUI, just make them all .frame(maxHeight: .infinity) and then make the container they're in .fixedSize(horizontal: false, vertical: true). In this instance, '.fixedSize()' really means 'minimum size'.…
-
MapKit Tutorial Videos
Stewart Lynch has made a YouTube playlist of MapKit tutorial videos.
-
Landscape vs Portrait
This post shows how to tell if you're landscape or portrat. GeometryReader { geometry in if geometry.size.height > geometry.size.width { print("portrait") } else { print("landscape") } But Apple suggests that you…
-
Internationalisation / Localisation / Translation
If I'm doing it all myself (or managing translations via chat or Discord or something), then I just need TranslateKit. If I want to crowd-source the translations, and/or allow folks to do it themselves in their own time on a separate system, I could…
-
Brother, I need a printer.
Need a new printer, in 2024? Maybe have a read of this.
-
@Observable
Might need to make my state class @Observable. As always, Paul has my back.
-
Swift fatalError()
To trigger a fatal error, you want Paul's guide to fatalError().
-
async button
Mahid has an interesting idea for an async button. struct AsyncButton<Label: View>: View { let action: () async -> Void let label: Label @State private var isRunning = false init( action: @escaping () async -> Void, …
-
Rock pools
... and other lovely swimming spots. The folks at Kids in Adelaide have put together a list.
-
Game Tile Image Assets
... for free! :) From Kenney.
-
Testing Network Code in Swift
As with most Swift / SwiftUI questions, the answer is to see what Paul has written about it.
-
One Target, One Scheme, Two Build Configs
Rather than having two separate Targets and two separate Schemes, maybe just have one of each. We can get different Info.plist values by having one Custom iOS Target Property set to a Build Setting, and then have two values for that Build Setting. One for…
-
Clear UserDefaults
To clear all UserDefaults from an app, maybe try this: if let appDomain = Bundle.main.bundleIdentifier { UserDefaults.standard.removePersistentDomain(forName: appDomain) } Thanks to Sourabh Sharma for this idea. Or maybe…
-
Lucky
I am very fortunate in my work. I'm paid a decent amount, to do work that is (mostly) quite interesting, with people who are good to work with. That said, I'd rather be building my Lego Great Wave.