Member-only story
Building a Real-Time Pattern Detector with iOS 26’s TextEditor and AttributedString
An example I’ve built for IcySky
TextEditor finally supports AttributedString with the iOS 26 SDK!
Inspired by the following WWDC25, I decided it was time to finally try it for my IcySky app!
Apple also released a very cool sample here:
As it’s a social network app for BlueSky, it’s a perfect candidate, as I need to highlight text like mentions, hashtags, and URLs. Until now, we had to wrap a UITextView in a SwiftUI representable in order to do that. Well, not anymore!
Here’s the story of how I built automatic pattern detection that actually works, why you can’t just follow Apple’s documentation blindly, and how the new constraint-based formatting APIs are…