Point-Free is a video series exploring advanced topics in the Swift programming language, hosted by industry experts, Brandon and Stephen.
We continue our series on “modern persistence” with an important topic: “callbacks.” Callbacks are little hooks into the lifecycle of your data model so that you can be notified or take action when something changes. We will first explore the “Active Record” pattern of callbacks, popularized by Ruby on Rails, and then see how we can improve upon them.
How does our SQL-based solution for persistence compare with modern SwiftData? We put things to the test by rebuilding our complex @FetchAll
query using @Model
and the @Query
macro!
We finish a sneak peek of our upcoming Structured Queries library by showing how queries built with the library can be reused and composed together, and how we can replace all of the raw queries in our application with simpler, safer query builders.
With our database migrated, it’s time to take the SyncEngine
for a spin to see how it seamlessly synchronizes data to and from iCloud, how it resolves conflicts when records are edited and deleted from multiple devices, and even how records are synchronized from different versions of the application and database schema.
We show how to add iCloud synchronization to the persistence layer of an existing SQLite application by using SQLiteData. While SQLiteData’s CloudKit tools can be configured with a single line of code, one must still prepare their database schema to be compatible and durable when it comes to synchronizing across multiple devices and versions.
We round out modern search by diving into FTS5’s query syntax language. We’ll learn how it works, how to escape terms sent directly by the user, and we’ll introduce SwiftUI search tokens that can refine a query by term proximity and tags.
We dissect some of the most important and interesting topics in Swift programming frequently, and deliver them straight to your inbox.
We cover both abstract ideas and practical concepts you can start using in your code base immediately.
Download a fully-functioning Swift playground from the episode so you can experiment with the concepts discussed.
We transcribe each video by hand so you can search and reference easily. Click on a timestamp to jump directly to that point in the video.
The Swift language has grown over the years and become more and more powerful. It now boosts a comprehensive static type system (generics, existentials…), a suite of concurrency tools (actors, dynamic isolation…), and most recently even ownership capabilities (consuming, borrowing, non-copyable types…). In “Back to basics” we will focus on just one part of the language in order to uncover the deep theory behind that feature as well as provide concrete advice for writing real-world code.
SwiftUI may be all the rage these days, but that doesn’t mean you won’t occassionally need to dip your toes into the UIKit waters. Whether it be to access some functionality not yet available in SwiftUI, or for performance reasons (UICollectionView
😍), you will eventually find yourself subclassing UIViewController
, and then the question becomes: what is the most modern way to do this?
Architecture is a tough problem and there’s no shortage of articles, videos and open source projects attempting to solve the problem once and for all. In this collection we systematically develop an architecture from first principles, with an eye on building something that is composable, modular, testable, and more.
If you have ever created a binding using the get:set:
initializer, you may want to reconsider. Doing so can hurt SwiftUI’s ability to animate your view. Luckily there is a better way. You can leverage @dynamicMemberLookup
and subscripts to derive new bindings in a way that allows SwiftUI to propertly track where the binding came from.
SwiftData is not capable of filtering and sorting by raw representable enum properties in models. Predicates and sort descriptors will compile just fine when referencing enum properties, but it will crash at runtime.
SwiftData is not capable of sorting by boolean properties in models. And if you try to trick SwiftData to allow it, you will encounter runtime crashes.
Please stop releasing one amazing video after the other! I'm still at Episode 15! #pointfreemarathon #androiddevhere
I listened to the first two episodes of @pointfreeco this weekend and it was the best presentation of FP fundamentals I've seen. Very thoughtful layout and progression of the material and motivations behind each introduced concept. Looking forward to watching the rest!
@pointfreeco ❤️: Thank you! 🧠: … The brain can’t say anything. It is blown away (🤯)!
Just became a subscriber! I'm binge watching episodes now! Great content! I'm learning so much from you guys. The repo for the site is the best go-to reference for a well done project and swift-web is something I am definitely going to use in my projects. Thanks for everything!
Watching the key path @pointfreeco episodes, and I am like 🤯🤯🤯. Super cool
After diving into @pointfreeco series reading Real World Haskell doesn’t seem all that intimidating after all. Major takeaway: the lesser is word “monad” is mentioned the better 😅
Thanks @mbrandonw @stephencelis for the very pedagogical series with @pointfreeco Excited and looking forward to learn from the series
Due to the amount of discussions that reference @pointfreeco, we added their logo as an emoji in our slack.
My new favourite morning routine is feeding 👶🏻 while watching @pointfreeco
Our free plan includes 1 subscriber-only episode of your choice, access to 73 free episodes with transcripts and code samples, and weekly updates from our newsletter.