Tailrocks swift best practices
Skill tailrocks/tailrocks-skills/skills/tailrocks-swift-best-practices
Apply Swift code policy when writing in-scope Swift, SwiftUI, concurrency, state ownership, accessibility, availability, or narrow AppKit bridges. Not review, refactoring, project setup, Rust-core boundary architecture, or visual-design authority.From its SKILL.md
npx -y skills add tailrocks/tailrocks-skills --skill tailrocks-swift-best-practicesAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its file declares
Copied from the file, not written here
The file declares its own license as Apache-2.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.
SKILL.md
3.0 KB, as published. Nobody here has run it
Swift Best Practices
Write native macOS/iOS Swift behavior for the active task. SwiftUI on Apple's modern rendering stack is the default; AppKit is a narrow capability bridge. Selection supplies policy, never mutation or tool authority.
Project tooling routes by outcome to the tailrocks-swift-project-* family;
visual/material
policy belongs to tailrocks-macos-design; Rust-core and Apple-platform effect
architecture belongs to tailrocks-swift-rust-core-boundary. Refuse findings-only
review and behavior-preserving refactor requests; route them to
tailrocks-swift-review or tailrocks-swift-refactor.
Apply runtime-trust.md. Load only the relevant
code reference:
| Decision | Reference |
|---|---|
| Actor isolation, Sendable values, tasks, cancellation | concurrency.md |
| State ownership, view identity, body work, layout | swiftui.md |
| Narrow capability-only AppKit bridge | appkit-interop.md |
| Typed failure, API and availability | errors-and-api.md |
| Semantics, focus, keyboard, verification IDs | accessibility.md |
Write
- Bind the platform contract. Record approved paths/behavior, minimum target, current SDK lane, state/isolation owners, capability gaps, accessibility and fallback obligations, and existing gates. Never invent an absent symbol; label the verified-SDK replacement point. Complete when: authority and availability are explicit.
- Design ownership first. Choose one isolation category per type, place
state at the lowest spanning node, keep identity stable and work out of
body, make tasks cancellable, and expose typed failures. Complete when: lifecycle and failure ownership are visible. - Implement the smallest native behavior. Use SwiftUI first; require a named current-stable SwiftUI capability gap for AppKit. Every newer symbol gets an availability guard, decided fallback, and removal condition. Business logic stays in Rust. Complete when: no second architecture or suppressed race exists.
- Verify and report. Add failure/cancellation tests and complete label, value, role, focus order, identifier, keyboard, and menu parity. Run only task-authorized existing bounded gates. Report changes, SDK/target, fallbacks, outcomes, and skips. Complete when: every breakable path has evidence.
Final gate
Strict concurrency, stable identity, guarded availability, typed failure, complete accessibility/input parity, native rendering, and no domain behavior in Swift.