Koskamo

SwiftUI best practices

Source-linked guidance on SwiftUI fundamentals: views and view composition, state and data flow, layouts and stacks, navigation, and previews and testing. Scoped to current SwiftUI docs.

Documents

Showing 1–5 of 5 documents

DocumentVersion

Creating and combining views

Modifiers wrap a view to change its display or other properties; each modifier returns a new view, so it is common to chain multiple modifiers, stacked vertically. Use the…

v1

HStack

Unlike LazyHStack, which renders views only when displayed onscreen, HStack renders all subviews simultaneously regardless of on- or offscreen status. Use regular HStack for…

v1

Managing model data in your app

When environment object availability is unguaranteed, retrieve an optional version to safely return nil instead of throwing an exception. To reflect changed data, use Observation…

v1

NavigationStack

Use a navigation stack to present a stack of views over a root view. People can add views to the top of the stack by clicking or tapping a NavigationLink, and remove views using…

v1

XCTest

Use the XCTest framework to write unit tests that integrate seamlessly with Xcode’s testing workflow. Tests assert that certain conditions are satisfied during code execution and…

v1

Source, review, and usage
Published on Koskamo by
Koskamo editorial
Version
1
Documents
5 documents
Reviewed
2026-10-04
Agent lookups
0 in the last 90 days
Reuse
Original summaries; linked sources retain their own terms.
Review status
Maintained with the application; source links supplied

Original sources are linked on each document. Owner approval records a publishing decision; it does not imply independent fact checking.

Use this dataset from an agent

Agents can query it without an account. POST to /api/v1/retrieve, or connect an MCP client and call koskamo_retrieve with dataset: "swiftui-best-practices".

The JSON endpoint returns document text and source links in pages. Use limit and offset to retrieve more records; total gives the dataset size.

retrieve request
curl --fail-with-body 'https://koskamo.com/api/v1/retrieve' -H 'Content-Type: application/json' --data-raw '{"query":"swiftui-best-practices","dataset":"swiftui-best-practices","top_k":3}'

Change history

This dataset is maintained with the application. Its history is the Koskamo release history; the review date above is when its sources were last checked.