convez.ai
Skill
SwiftyJourney

swift-language-expert-skill

SwiftyJourney/swift-language-expert-skill

Ver no GitHub
InicialPluginScore · de 0 a 100

Non-obvious Swift language & standard-library techniques: value semantics, generics, collections, strings, concurrency - Agent Skill

Instalação

$npx convez-ai SwiftyJourney/swift-language-expert-skill

1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.

Métricas

Estrelas
0
Forks
0
Acompanhando
0
Saúde
37%
Último commit
há 3 meses
Versão
—
Issues abertas
0
Contribuidores
1

README

A tradução para o português deste README ainda está na fila.

Swift Language Expert Agent Skill

License: MIT Agent Skills

A Claude Code skill for non-obvious Swift language and standard-library techniques — the features that make code clearer, safer, or faster but that developers routinely miss. This skill is about the language itself, not SwiftUI, app architecture, or a test framework.

Who is this for?

Swift developers who want idiomatic, modern answers to "how do I do X in Swift":

  • Pattern matching and control flow (if/guard case, switch over tuples and ranges, optional patterns)
  • Functions, closures, and key paths (variadics, autoclosures, rethrows, key-path expressions)
  • Value semantics and custom types (copy-on-write, ~Copyable, callAsFunction, Comparable, recursive enums, property wrappers)
  • Protocols and generics (associated types, Self, opaque some vs existential any, phantom types)
  • Collection algorithms (lazy sequences, RangeSet, ContiguousArray/InlineArray, sorting)
  • Strings and Unicode (grapheme-correct iteration, String.Index, raw strings, custom interpolation)
  • Language-level concurrency and error handling (async/await, task groups, AsyncSequence/AsyncStream, typed throws)
  • Debugging and code organization (assertions, dump, enum namespaces, compiler directives)

Installation

Install via skills.sh:

npx skills add SwiftyJourney/swift-language-expert-skill

Compatible Agents

What the Skill Covers

AreaTopics
Control flow & functionsPattern matching (if/guard case, tuple switch); variadics, autoclosures, rethrows; key paths as values and functions
TypesValue semantics, copy-on-write, ~Copyable, callAsFunction, Comparable/literal conformances, recursive enums, property strategies
GenericsAssociated and primary associated types, some vs any, phantom types, constraints, the default-implementation dispatch trap
DataLazy sequences, RangeSet/DiscontiguousSlice, ContiguousArray/InlineArray, sorting; strings, String.Index, and Unicode
Concurrency & errorsasync let, task groups, AsyncSequence/AsyncStream, continuations, typed throws, cooperative cancellation
ToolingAssertions vs preconditions, dump, os.Logger, type subscripts, enum namespaces, compiler directives

Skill File Structure

SKILL.md                                  # Hub: behavior contract, diagnostic table, reference router
references/
├── pattern-matching-and-control-flow.md   # if/guard case, switch over tuples/ranges, optional patterns
├── functions-closures-keypaths.md         # variadics, autoclosures, rethrows, overloading, key paths
├── custom-types.md                        # value semantics, copy-on-write, ~Copyable, callAsFunction, conformances
├── protocols-and-generics.md              # associated types, Self, some vs any, phantom types, constraints
├── collections.md                         # lazy, RangeSet/DiscontiguousSlice, ContiguousArray/InlineArray, sorting
├── strings.md                             # String.Index, Unicode/graphemes, raw strings, custom interpolation
├── concurrency-and-errors.md              # async/await, task groups, AsyncSequence/AsyncStream, typed throws
└── debugging-and-organization.md          # assertions, dump, type subscripts, enum namespaces, directives

Related Skills

  • SwiftUI Expert — SwiftUI view code: state, composition, performance, animations, accessibility
  • iOS Architecture Expert — Clean modular architecture: composition root, protocol boundaries, generic presenters, Swift 6 concurrency
  • Requirements Engineering — Turn vague requirements into testable specs: BDD, use cases, contracts, diagrams
  • SwiftUI ⇄ UIKit Interop — Bridge SwiftUI and UIKit: hosting controllers, representables, data across the boundary

Credits

  • Natalia Panferova (Nil Coalescing) — "Swift Gems", which informed the language and standard-library techniques distilled here
  • Apple — The Swift Programming Language, Swift Evolution, and standard-library documentation

License

MIT — see LICENSE.

Ver o original no GitHub

Bom para

Relacionados