// Shorts

One concept at a time

Modern mobile APIs explained in about two minutes each — what problem it solves, working code, and the trap you'll hit the first time you use it.

74 shorts

SwiftUI

20
01iOS 17+2 min

@Observable: State Without the Boilerplate

The @Observable macro replaces @Published and ObservableObject with less code and smarter view invalidation.

swiftuistate
02iOS 17+2 min

@Bindable: Two-Way Bindings Into @Observable

@Bindable unlocks two-way SwiftUI bindings into an @Observable class without giving up single ownership.

swiftuibindings
03iOS 18+2 min

@Entry: Custom Environment Values in One Line

The @Entry macro turns a multi-step EnvironmentKey into one line for custom environment and focus values.

swiftuienvironment
04iOS 17+2 min

ContentUnavailableView: The Empty State You Don't Have to Build

ContentUnavailableView gives every app the same polished empty state and no-search-results screen for free.

swiftuiempty-states
05iOS 17+2 min

.inspector: One Modifier, Every Platform's Detail Pane

The .inspector modifier adds a trailing detail pane that adapts automatically across iPhone, iPad, and Mac.

swiftuilayout
06iOS 17+2 min

scrollTargetBehavior: Snapping Carousels, No UIKit

Build a paging, view-aligned carousel with plain SwiftUI — no UICollectionView, no compositional layout.

swiftuiscrolling
07iOS 17+2 min

scrollPosition(id:): Reading and Driving Scroll Position

A two-way binding to the currently scrolled item — jump to content and observe scroll position with one API.

swiftuiscrolling
08iOS 17+2 min

containerRelativeFrame: Sizing Children as a Fraction of Their Container

Size a view as a percentage of its scroll view or container without a GeometryReader in sight.

swiftuiscrolling
09iOS 17+2 min

scrollTransition: Per-Item Effects Driven by Scroll Phase

Scale and fade carousel items as they enter and leave the viewport, without measuring frames yourself.

swiftuiscrolling
10iOS 18+2 min

onScrollGeometryChange: Scroll Offset Without GeometryReader Hacks

Observe raw scroll offset directly on the ScrollView, no PreferenceKey plumbing required.

swiftuiscrolling
11iOS 17+2 min

phaseAnimator: Multi-Step Animation in One Modifier

Sequence a bump, settle, and rest animation without chaining withAnimation calls or DispatchQueue delays.

swiftuianimation
12iOS 17+2 min

KeyframeAnimator: Independent Timelines Per Property

Animate scale, offset, and rotation on their own timelines with keyframeAnimator, instead of one shared curve.

swiftuianimation
13iOS 17+2 min

symbolEffect: Native Animation for SF Symbols

Bounce, pulse, and morph SF Symbols with built-in effects instead of hand-rolled scale and crossfade tricks.

swiftuianimation
14iOS 16+2 min

contentTransition(.numericText()): Odometer-Style Numbers

Roll digits up or down like an odometer when a number changes, with one modifier and no custom digit views.

swiftuianimation
15iOS 17+2 min

visualEffect: Geometry-Driven Effects, No GeometryReader

Scale scroll-carousel cards by their position using visualEffect, without wrapping each card in a GeometryReader.

swiftuianimation
16iOS 18+2 min

MeshGradient: Real Gradient Meshes in SwiftUI

SwiftUI's MeshGradient renders true multi-point gradient meshes natively, replacing hacky stacks of blurred RadialGradients.

swiftuigraphics
17iOS 18+2 min

Tab and .sidebarAdaptable: One Tab Bar for iPhone and iPad

The new Tab builder plus .tabViewStyle(.sidebarAdaptable) turns one TabView into an iPad sidebar and an iPhone tab bar automatically.

swiftuinavigation
18iOS 18+2 min

Hero Zoom Push Transitions with navigationTransition(.zoom)

.navigationTransition(.zoom) turns a NavigationStack push into a hero zoom transition with no custom animation code.

swiftuinavigation
19iOS 26+2 min

glassEffect(): Liquid Glass on Custom Views

.glassEffect() applies Apple's iOS 26 Liquid Glass material to any custom view with a single modifier.

swiftuiliquid-glass
20iOS 26+2 min

GlassEffectContainer: Morphing Glass Elements

GlassEffectContainer groups glass views so they sample light together, and glassEffectID morphs one glass shape into another.

swiftuiliquid-glass

Swift

11
53Swift 5.5+2 min

async/await: Replacing Completion Handlers

async/await turns nested completion handler pyramids into linear, readable code the compiler can check.

swiftconcurrency
54Swift 5.5+2 min

Structured Concurrency: async let and TaskGroup

async let and TaskGroup run child tasks in parallel while guaranteeing they finish before the enclosing scope exits.

swiftconcurrency
55Swift 5.5+2 min

Actors: Data Race Protection by Construction

Actors serialize access to their mutable state so the compiler, not a lock or a queue, prevents data races.

swiftconcurrency
56Swift 5.7+2 min

Sendable and Why the Compiler Shouts at You

Sendable marks types that are safe to pass across concurrency domains, and the compiler enforces it at every boundary.

swiftconcurrency
57Swift 5.5+2 min

@MainActor: What It Actually Guarantees

@MainActor guarantees isolation to the main actor's serial executor, which in practice means the main thread, not synchronous execution.

swiftconcurrency
58Swift 5.5+2 min

withCheckedThrowingContinuation: Bridging Callback APIs

Continuations wrap a callback-based API in a single async call, as long as the callback is invoked exactly once.

swiftconcurrency
59Swift 5.5+2 min

AsyncSequence and AsyncStream

AsyncSequence turns a stream of future values into something you can loop over with for-await, and AsyncStream builds one from callbacks.

swiftconcurrency
60Swift 5.5+2 min

Task Cancellation Is Cooperative

Cancelling a Task only flips a flag — the running code has to check it and stop itself, or it keeps running to completion.

swiftconcurrency
61Swift 5.9+2 min

Writing an Attached Macro

Attached macros generate code from a declaration you annotate, expanded at compile time and checked by the type checker.

swiftconcurrency
62Swift 5.4+2 min

Result Builders: How @ViewBuilder Actually Works

@resultBuilder turns a sequence of statements into a single composed value, which is the mechanism SwiftUI's @ViewBuilder is built on.

swiftconcurrency
63Swift 6+2 min

Typed Throws and Richer Error Signatures

Typed throws let a function declare exactly which error type it throws, so callers can catch it exhaustively without casting.

swiftconcurrency

Apple Frameworks

11
64iOS 17+2 min

SwiftData: @Model and the Modern Persistence Stack

SwiftData replaces Core Data's NSManagedObject ceremony with a plain Swift @Model macro and a Swift-native container.

swiftdataios
65iOS 17+2 min

@Query, Predicates, and Sorting in SwiftData

@Query keeps SwiftUI views in sync with SwiftData automatically, driven by #Predicate and SortDescriptor.

swiftdataios
66iOS 14+2 min

WidgetKit: Timelines and Reload Policies

WidgetKit renders a widget from a pre-built schedule of entries, not a continuously running process.

widgetkitios
67iOS 16+2 min

App Intents: Making Your App Scriptable and Siri-Visible

App Intents replaces SiriKit's fixed intent domains with a Swift protocol any app action can conform to.

appintentsios
68iOS 16.1+2 min

Live Activities and the Dynamic Island

ActivityKit keeps a live-updating view on the Lock Screen and Dynamic Island in sync, locally or via push.

activitykitios
69Xcode 16+2 min

Swift Testing: @Test, #expect, and Parameterised Tests

Swift Testing replaces XCTest's class-and-assertion ceremony with free functions, macros, and native parameterisation.

swift-testingtesting
70iOS 15+2 min

StoreKit 2: Purchases Without the Ceremony

StoreKit 2 replaces payment queue observers and receipt parsing with async/await and signed transaction values.

storekitios
71iOS 16+2 min

Swift Charts: Declarative Data Visualisation

Swift Charts builds charts out of SwiftUI-style marks instead of hand-rolled Core Graphics drawing code.

swift-chartsios
72iOS 13+2 min

On-Device Inference with Core ML and Vision

Core ML and Vision run trained models and image analysis directly on-device, no network round trip required.

coremlvision
73iOS 13+2 min

BGTaskScheduler: Work That Survives Backgrounding

BGTaskScheduler lets iOS decide when to wake your app for maintenance work instead of you fighting for background time.

background-tasksios
74iOS 15+2 min

os_signpost and Instruments for Real Performance Data

os_signpost emits custom timeline events Instruments can visualise, turning guesswork about slow code into real data.

instrumentsperformance

Jetpack Compose

12
21Compose 1.0+2 min

derivedStateOf: Stop Recomposing on Every Scroll Pixel

Derive booleans from fast-changing state so composables only recompose when the derived value actually changes.

androidcompose
22Compose 1.0+2 min

Stable Keys in LazyColumn: Why Item Identity Matters

Give LazyColumn items a stable key or Compose loses item state and over-recomposes on every list mutation.

androidcompose
23Compose 1.0+2 min

LaunchedEffect vs DisposableEffect vs SideEffect

Three effect APIs for three jobs: coroutine work, cleanup-requiring subscriptions, and publishing state out of Compose.

androidcompose
24Compose compiler 1.4+2 min

Stability, @Immutable/@Stable, and Skippable Composables

The Compose compiler only skips recomposition when it can prove a composable's parameters are stable.

androidcompose
25Compose 1.0+2 min

Modifier Order Changes the Result: padding vs size vs background

Modifier chains apply outside-in in the order written — swap padding and background and you get a different layout.

androidcompose
26Compose 1.0+2 min

State Hoisting: Stateless Composables You Can Actually Reuse

Move mutable state out of a composable and up to its caller so the composable becomes reusable and testable.

androidcompose
27Compose 1.0+2 min

snapshotFlow: Bridging Compose State to Flow

Turn any Compose State read into a cold Flow that emits on distinct changes, with the full set of Flow operators.

androidcompose
28Compose 1.7+2 min

Shared Element Transitions in Compose

Animate a thumbnail morphing into its detail view with SharedTransitionLayout instead of a hard navigation cut.

androidcompose
29Android 14+2 min

Predictive Back Gestures in Compose

Animate the UI as the user drags the back gesture instead of jump-cutting away once it completes.

androidcompose
30Compose Material3 1.1+2 min

WindowSizeClass for Adaptive Layouts

Branch layout structure on coarse width/height buckets instead of hardcoding phone-only dimensions.

androidcompose
31Compose Multiplatform 1.6+2 min

Compose Multiplatform Resources: One Res Object, Every Target

Share drawables and strings across Android, iOS, and desktop from a single composeResources source set.

kotlin-multiplatformcompose
32Android Studio Giraffe+2 min

Finding Needless Recomposition with the Layout Inspector

Turn on recomposition counts in Android Studio to see exactly which composables are re-running, and why.

androidcompose

React Native

10
33React Native 0.72+2 min

Fabric: The New Architecture Renderer in Plain Terms

Fabric replaces the old UIManager bridge with a synchronous, thread-safe renderer built on JSI.

react-nativeperformance
34React Native 0.73+2 min

TurboModules: Lazy Native Modules and Codegen

TurboModules load native modules lazily and type-check them via codegen instead of the untyped NativeModules bridge.

react-nativenative-modules
35React Native 0.74+2 min

JSI and Bridgeless Mode: What Actually Changed

JSI replaces the async JSON bridge with direct C++ host object bindings, and bridgeless mode removes the bridge entirely.

react-nativearchitecture
36Reanimated 3.0+2 min

Reanimated Worklets: Animation Off the JS Thread

Worklets run small JS functions on the UI thread so gesture-driven animations don't stutter when the JS thread is busy.

react-nativereanimated
37FlashList 1.6+2 min

FlashList: Fixing FlatList Performance

FlashList recycles views instead of remounting them, fixing FlatList's blank-cell flicker and memory growth on long lists.

react-nativeperformance
38Expo SDK 50+2 min

Expo Router: File-Based Navigation

Expo Router turns your file tree into your navigation graph, replacing manually wired React Navigation stacks.

react-nativeexpo
39React Native 0.70+2 min

Hermes: Bytecode, Startup Time, and When It Helps

Hermes precompiles JS to bytecode at build time, trading a slower build for faster app startup and lower memory use.

react-nativehermes
40React Native 0.76+2 min

Migrating an App to the New Architecture

Turning on Fabric and TurboModules is one flag, but every native dependency in your tree has to support it first.

react-nativemigration
41React Native 0.74+2 min

Writing a Native Module in Swift and Kotlin

A TurboModule needs a typed JS spec plus matching Swift and Kotlin implementations generated from the same codegen contract.

react-nativenative-modules
42React Native 0.73+2 min

Profiling Render Performance and Dropped Frames

Finding a jank source means correlating a dropped-frame timeline with which JS render or native operation was running then.

react-nativeperformance

Kotlin Multiplatform

10
43Kotlin 1.9+2 min

expect/actual: The Core of Shared Kotlin Code

expect/actual lets shared Kotlin code declare an API once and have each platform supply its own implementation.

kmpkotlin
44Kotlin 1.9.20+2 min

Source Sets and the Hierarchy Template

Kotlin Multiplatform's default hierarchy template auto-creates intermediate source sets so iOS targets share code without manual wiring.

kmpkotlin
45Kotlin 1.7.20+2 min

Sharing Coroutines and Flow Across Platforms

Kotlin/Native's coroutine runtime lets commonMain code use suspend functions and Flow exactly like JVM code.

kmpkotlin
46Ktor 2.3+2 min

Ktor Client as the Shared Networking Layer

Ktor's multiplatform HTTP client puts request building, serialization, and error handling in one shared networking layer.

kmpkotlin
47SQLDelight 2.0+2 min

SQLDelight: Typed SQL Shared Across Platforms

SQLDelight generates typed Kotlin query APIs from real SQL, shared across Android and iOS with per-platform drivers.

kmpkotlin
48Kotlin 1.9+2 min

Consuming a KMP Module from Swift

Kotlin/Native compiles shared code to a framework Swift calls directly, with suspend functions arriving as completion handlers.

kmpkotlin
49Compose Multiplatform 1.6+2 min

Compose Multiplatform: Sharing UI, and When Not To

Compose Multiplatform shares full screens across Android and iOS via Skia, but native idioms are still sometimes the better call.

kmpkotlin
50Koin 3.5+2 min

Dependency Injection in Shared Code with Koin

Koin builds one dependency graph in commonMain, started from each platform's entry point without reflection.

kmpkotlin
51Kotlin 1.9+2 min

Testing Shared KMP Code Across Targets

kotlin.test gives commonTest one assertion API that runs as JUnit on Android and as a native binary on iOS.

kmpkotlin
52Kotlin 1.9+2 min

cinterop: Calling Platform C/Objective-C APIs

cinterop generates Kotlin bindings for C and Objective-C libraries, letting shared iOS code call system frameworks directly.

kmpkotlin