-
SwiftUI Data Flow
SwiftUI gives us a completely new way to lay out out user interfaces, in a declarative and responsive way. Your data dictates what is displayed. But this leads to a new problem - how should the data models be constructed and how can they be passed around between the various views that make up your app?
In this post, I intend to discuss the possibilities with examples.
Update - January 2021: I think the information in this post is still all valid except for one change. When you are initializing an ObservableObject, you should use
@StateObject
instead of@ObservedObject
. Your views can receive objects that are owned by other views as@ObservedObject
or@EnvironmentObject
but the owner of the data should always create the data object with@StateObject
. -
Crossfix
I have just released Crossfix and Crossfix Lite for iPhone. They are both the same anagram assistant solver for crosswords, particularly cryptic crosswords. The Lite version is free but limits you to three solves per day. The full version is unlimited with no ads, no recurring subscriptions and works with family sharing.
-
SwiftUI for Mac on Big Sur
In December 2019, I wrote a series of articles about using SwiftUI to build a Mac app. At WWDC 2020, Apple announced macOS 11 Big Sur along with Xcode 12 and a heap of new features for SwiftUI, so I decided to try creating my test app again and seeing how much had changed.
-
SwiftUI Snapshot Testing
Snapshot testing is a technique that has been very popular in the web development world and it seems like a great way to test SwiftUI user interfaces. I read about snapshot tests in a recent blog post and was intrigued, but I had some difficulty getting it to work, so when I finally succeeded, I decided to share my experiences in the hope that others will find them useful.
-
Name This App
My current work in progress is an iPhone app designed to make it easier to solve crossword anagrams by emulating and improving upon an ability that was there when we used to do crosswords on paper, but is missing for digital crosswords.
But I cannot think of a clever name for the app, so please read the story and contact me with your name suggestions or if you would like to test the pre-release version of this app.