pfw-swift-navigation

Manage Swift navigation state with enum-based destinations and SwiftNavigation.

16|2|Updated Mar 29, 2018
One-click install
npx skills add https://github.com/khoi/dotfiles --skill pfw-swift-navigation-khoi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pfw-swift-navigation
Source: https://github.com/khoi/dotfiles/tree/main/chezmoi/dot_pfw/skills/swift-navigation
Command: npx skills add https://github.com/khoi/dotfiles --skill pfw-swift-navigation-khoi

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Complex navigation state in Swift apps is hard to model, test, and maintain. pfw-swift-navigation provides a structured approach using enums and the SwiftNavigation library to unify navigation logic across SwiftUI and UIKit.

Core Features & Use Cases

  • Enum-based destination modeling for clear, type-safe navigation
  • State-driven presentation across SwiftUI and UIKit (sheet, fullScreenCover, popover, alerts)
  • Cross-platform guidance for applying SwiftNavigation patterns in non-SwiftUI contexts

Quick Start

Install and wire the SwiftNavigation package to enable enum-driven navigation in your app.

Frequently Asked Questions about pfw-swift-navigation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I manage SwiftUI navigation state with enums?

SwiftUI navigation state can be managed with enums by modeling destinations type-safely and using the SwiftNavigation package to drive sheet, alert, and full-screen presentations. This approach unifies navigation logic for easier testing and maintenance.

Can I use SwiftNavigation patterns in UIKit apps?

Yes, SwiftNavigation patterns apply to UIKit apps. The Skill provides cross-platform guidance to help you integrate state-driven navigation logic and presentation patterns like sheets and alerts within non-SwiftUI contexts.

What is the best way to handle complex navigation state in Swift?

The best way to handle complex navigation state in Swift is using enum-based destination modeling. This structured approach makes navigation logic clear and type-safe, simplifying state management across SwiftUI and UIKit targets.

How do I present full-screen covers and sheets using state-driven navigation?

You present sheets and full-screen covers by wiring the SwiftNavigation package into your app. This enables state-driven presentations, automatically mapping your enum navigation state to the correct SwiftUI or UIKit view presentations.

Does this state-driven navigation approach work across cross-platform Swift targets?

Yes, this state-driven navigation approach is designed for cross-platform Swift targets. It applies unified navigation patterns across SwiftUI and UIKit, ensuring consistent state management and presentation logic for sheets and alerts.