Reading time: 6 min

Pull to refresh is a common UI pattern, supported in UIKit via UIRefreshControl. (Un)surprisingly, it's also unavailable in SwiftUI. (EDIT: It's been added in SwiftUI 3 - however, it has many drawbacks compared to this solution.)

This recipe shows how to implement this functionality with any ScrollView. It also doesn't rely on UIViewRepresentable.

Continue Reading...