Type Safely

Type Safely

Set a SwiftUI Published Property To A Codable Structure From JSON Data

Daily Coding Tip 018

Type Safely's avatar
Type Safely
Jan 05, 2021
∙ Paid
Image by Tri Le from Pixabay

This is based on a post on my Substack, but I’ve expanded it into a working example.

I haven’t worked with Combine much, but I wanted an easy way to get data into my SwiftUI project without using the conventional URLRequest.dataTask.

Instead of creating a Publisher in my ObservableObject, I decided to create an extension of URL…

User's avatar

Continue reading this post for free, courtesy of Type Safely.

Or purchase a paid subscription.
© 2026 Type Safely · Privacy ∙ Terms ∙ Collection notice
Start your SubstackGet the app
Substack is the home for great culture