Deciding between ‘let’ and ‘var’ for Swift struct properties
Does marking a given Swift struct property as either ‘let’ or ‘var’ simply determine its mutability, or is there more to it? Let’s explore!
Articles and podcasts about Swift development, by John Sundell.
Presented by the Genius Scan SDK
Swift by Sundell is frequently updated with new articles, podcast episodes, videos, and more.
Subscribe via RSS to get notified when new content gets published.
Does marking a given Swift struct property as either ‘let’ or ‘var’ simply determine its mutability, or is there more to it? Let’s explore!
How Swift’s CodableWithConfiguration API can be used to inject additional, required data into a type’s decoding process, without having to use optionals or declare any additional decoding-specific types.
Let’s explore how we can use SwiftUI’s ViewBuilder within our own code, and a few things that can be good to keep in mind when doing so.
How Swift’s defer keyword can be incredibly useful when working with code scopes that have multiple exit points, such as throwing or async functions.
How to combine Foundation’s latest URL APIs with Swift features like macros, to be able to work with both static and dynamic URLs in simpler and more predictable ways.
After a two-year hiatus, Swift by Sundell is finally back, with new articles published on a regular basis.