サクサク読めて、アプリ限定の機能も多数!
トップへ戻る
ノーベル賞
www.swiftbysundell.com
Like its name implies, Swift’s property wrappers feature enables us to wrap a given property value within a custom type, which in turn lets us apply transforms and run other kinds of logic whenever that value is modified. By default, a property wrapper is completely disconnected from the enclosing types in which it’s being used, which can prove to be quite limiting in certain situations. For examp
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. SwiftUI offers multiple ways to connect a given view to the underlying state that it depends on, for example using property wrappers like @State and @Obs
Apple’s Combine framework enables us to model our asynchronous code as reactive pipelines that each consist of a series of separate operations. Those pipelines can then be observed, transformed, and combined in various ways — and since Combine makes heavy use of Swift’s advanced generics capabilities, that can all be done with a high degree of type safety and compile time validation. That strong t
When dealing with properties that represent some form of state, it’s very common to have some kind of associated logic that gets triggered every time that a value is modified. For example, we might validate each new value according to a set of rules, we might transform our assigned values in some way, or we might be notifying a set of observers whenever a value was changed. In those kinds of situa
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. Most apps tend to be centered around a small number of core models. For example, a navigation app might have models such as Route and Destination, while
Just like sequential code, concurrent code can come in many different shapes and forms. Depending on what we’re trying to achieve — whether that’s asynchronously fetching a piece of data, loading heavy files from disk, or performing a group of related operations — the abstraction that’ll prove to be the best fit might vary quite a lot from use case to use case. One such concurrent programming abst
The introduction of SwiftUI, Apple’s declarative new UI framework, was clearly one of the most impactful announcements made during this year’s WWDC conference. As a brand new way of building UIs for all of Apple’s platforms, using a coding style that’s vastly different from the way UIKit works, SwiftUI isn’t just a new framework — it’s a paradigm shift. As a new, modern take on UI development for
Articles, podcasts and news about Swift development, by John Sundell. One of the most interesting aspects of SwiftUI, at least from an architectural perspective, is how it essentially treats views as data. After all, a SwiftUI view isn’t a direct representation of the pixels that are being rendered on the screen, but rather a description of how a given piece of UI should work, look, and behave. Th
The iPad continues to be a source of much debate - not only in the iOS developer community, but in the tech industry at large as well. Will the iPad replace the Mac, can you get real work done on iOS, and should the iPad be treated as a proper computer? Whether or not you believe that the iPad is the future of computing, it does bring a ton of interesting new features and capabilities to the table
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. A DSL, short for Domain Specific Language, can be explained as a special kind of API that focuses on providing a simple syntax that's tailored to working
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. Every app that doesn't only consist of one single UI needs some form of navigation - to enable users to move between different screens and to display inf
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. Mocking is a key technique when it comes to writing unit tests in pretty much any language. When mocking an object, we are essentially creating a "fake"
Shared state is a really common source of bugs in most apps. It's what happens when you (accidentally or by design) have multiple parts of a system that rely on the same mutable state. The challenges (and bugs) usually come from not handling changes to such a state correctly throughout the system. This week, let's take a look at how shared state can be avoided in many situations, by using the fact
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. One of the hardest things when building apps and designing systems is deciding how to model and deal with state. Code managing state is also a very commo
Articles and podcasts about Swift development, by John Sundell. This article has been archived, as it was published several years ago, so some of its information might now be outdated. For more recent articles, please visit the main article feed. Swift’s @autoclosure attribute enables you to define an argument that automatically gets wrapped in a closure. It’s primarily used to defer execution of
このページを最初にブックマークしてみませんか?
『Swift by Sundell』の新着エントリーを見る
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く