Skill Wiki v0.1.0
principle @ios-swift/principle-Swift-as-progressive-disclosure

Swift As Progressive Disclosure

Build APIs and code in the same shape: the common case is a one-liner; the next-most-common case adds one explicit modifier; only the genuinely complex case pulls in the full machinery.…

Skill
@ios-swift
Domain
ios-swift
Version
0.1.0
Quality
4.0
Edges
5 out · 2 in
Tokens
260/424/424
$ prime install @ios-swift/principle-Swift-as-progressive-disclosure

Projection

Always in _index.xml · the agent never has to ask for this.

SwiftAsProgressiveDisclosure [principle] v0.1.0

Swift is designed so that the simple form is the default, and complexity is opted into one feature at a time. A user can write let x = 1 before they know about types; they can write func f() { ... } before they know about access control; they can write a struct before they need a protocol; they can use try before they need typed throws; they can call f() before they need await. Each feature waits until it is actually needed and only then enters the user's code.

Build APIs and code in the same shape: the common case is a one-liner; the next-most-common case adds one explicit modifier; only the genuinely complex case pulls in the full machinery. Default arguments, opt-in attributes (@MainActor, @Sendable, @escaping), and progressive type erasure (some P, any P) all exist so that a beginner's first use is short and a power user's specialised use is precise. Do not invert this by making the simple case carry decoration it does not need.

Source

prime-system/examples/ios-swift/primes/compiled/@ios-swift/principle-Swift-as-progressive-disclosure/atom.yaml

Compiled at 2026-05-10