functional-programming-developer

Functional Architecture in Swift

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "functional-programming-developer" with this command: npx skills add sideeffect-io/swift-functional-programming-skill/sideeffect-io-swift-functional-programming-skill-functional-programming-developer

Functional Architecture in Swift

Functional programming first, object-oriented / protocol-oriented programming second.

This skill guides how to design domain and core logic in Swift using immutability, pure functions, and explicit effects.

When to use

  • Domain modeling

  • Feature / business logic

  • Reducers and workflows

  • Dependency-injected use cases

  • Highly testable code

Architectural patterns

  • Functional Core / Imperative Shell

  • Feature-oriented design

  • Dependency injection via functions

  • Mealy & extended state machines

  • Effects as data

Functional techniques

  • Algebraic Data Types (enum + struct)

  • Functional operators (map, flatMap, reduce)

  • Partial application & currying

  • Optics (Lenses & Prisms with KeyPaths)

Reading order

  • references/state-machines.md

  • references/functional-operators.md

  • references/algebraic-data-types.md

  • references/optics.md

  • references/dependency-injection-currying.md

  • references/dependency-injection-decision-table.md

Dependency injection rules

  • Closures first

  • Capability structs second

  • Protocols last (boundary only)

Testing rules

  • Unit tests only in the core

  • Fake closures instead of mocks

  • No sleeps or timers

Summary

If it’s hard to test, simplify the design.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

swift-functional-architecture

No summary provided by upstream source.

Repository SourceNeeds Review
General

swiftui-expert

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

openclaw-version-monitor

监控 OpenClaw GitHub 版本更新,获取最新版本发布说明,翻译成中文, 并推送到 Telegram 和 Feishu。用于:(1) 定时检查版本更新 (2) 推送版本更新通知 (3) 生成中文版发布说明

Archived SourceRecently Updated
Coding

ask-claude

Delegate a task to Claude Code CLI and immediately report the result back in chat. Supports persistent sessions with full context memory. Safe execution: no data exfiltration, no external calls, file operations confined to workspace. Use when the user asks to run Claude, delegate a coding task, continue a previous Claude session, or any task benefiting from Claude Code's tools (file editing, code analysis, bash, etc.).

Archived SourceRecently Updated