[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M714R1VZPNQRGXTQ04Z04SFK":3,"skill-same:01M714R1VZPNQRGXTQ04Z04SFK":69},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":23,"publishedAt":44,"linkOnly":45,"markdownContent":46,"markdownBody":47,"frontMatter":48,"refName":49,"commitSha":50,"skillDirectory":51,"forksCount":14,"repositoryHtmlUrl":52,"repositoryHomepageUrl":6,"ownerHtmlUrl":53,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":54,"install":55,"resources":68},"01M714R1VZPNQRGXTQ04Z04SFK","swiftui-expert-skill",null,"Write, review, or improve SwiftUI code following best practices for state management, view composition, performance, and iOS 26+ Liquid Glass adoption. Use when building new SwiftUI features, refactoring existing views, reviewing code quality, or adopting modern SwiftUI patterns.","sapsapshen\u002Fai-memory-router","sapsapshen","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F20347959?v=4","01M6XDQEF1DP50DKF37H81J3J5","shenmian","01M6XDQEJPE41Y3DT2763X8ZJN",0,"MIT","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcopilot\u002Fswiftui-expert-skill\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43],"swiftui expert skill","swiftui","swiftui expert","expert","code quality","patterns","write","features","refactoring","swiftui patterns","review","code","liquid glass","unknown","when","new","improve","performance","Composition","community","2026-11-10 10:12:30",false,"---\nname: swiftui-expert-skill\ndescription: Write, review, or improve SwiftUI code following best practices for state management, view composition, performance, and iOS 26+ Liquid Glass adoption. Use when building new SwiftUI features, refactoring existing views, reviewing code quality, or adopting modern SwiftUI patterns.\nrisk: unknown\nsource: community\n---\n\n# SwiftUI Expert Skill\n\n## Overview\nUse this skill to build, review, or improve SwiftUI features with correct state management, optimal view composition, and iOS 26+ Liquid Glass styling. Prioritize native APIs, Apple design guidance, and performance-conscious patterns. This skill focuses on facts and best practices without enforcing specific architectural patterns.\n\n## Workflow Decision Tree\n\n### 1) Review existing SwiftUI code\n- **First, consult `references\u002Flatest-apis.md`** to ensure only current, non-deprecated APIs are used\n- Check property wrapper usage against the selection guide (see `references\u002Fstate-management.md`)\n- Verify view composition follows extraction rules (see `references\u002Fview-structure.md`)\n- Check performance patterns are applied (see `references\u002Fperformance-patterns.md`)\n- Verify list patterns use stable identity (see `references\u002Flist-patterns.md`)\n- Check animation patterns for correctness (see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`)\n- Review accessibility: proper grouping, traits, Dynamic Type support (see `references\u002Faccessibility-patterns.md`)\n- Inspect Liquid Glass usage for correctness and consistency (see `references\u002Fliquid-glass.md`)\n- Validate iOS 26+ availability handling with sensible fallbacks\n\n### 2) Improve existing SwiftUI code\n- **First, consult `references\u002Flatest-apis.md`** to replace any deprecated APIs with their modern equivalents\n- Audit state management for correct wrapper selection (see `references\u002Fstate-management.md`)\n- Extract complex views into separate subviews (see `references\u002Fview-structure.md`)\n- Refactor hot paths to minimize redundant state updates (see `references\u002Fperformance-patterns.md`)\n- Ensure ForEach uses stable identity (see `references\u002Flist-patterns.md`)\n- Improve animation patterns (use value parameter, proper transitions, see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`)\n- Improve accessibility: use `Button` over tap gestures, add `@ScaledMetric` for Dynamic Type (see `references\u002Faccessibility-patterns.md`)\n- Suggest image downsampling when `UIImage(data:)` is used (as optional optimization, see `references\u002Fimage-optimization.md`)\n- Adopt Liquid Glass only when explicitly requested by the user\n\n### 3) Implement new SwiftUI feature\n- **First, consult `references\u002Flatest-apis.md`** to use only current, non-deprecated APIs for the target deployment version\n- Design data flow first: identify owned vs injected state (see `references\u002Fstate-management.md`)\n- Structure views for optimal diffing (extract subviews early, see `references\u002Fview-structure.md`)\n- Keep business logic in services and models for testability (see `references\u002Flayout-best-practices.md`)\n- Use correct animation patterns (implicit vs explicit, transitions, see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`, `references\u002Fanimation-advanced.md`)\n- Use `Button` for tappable elements, add accessibility grouping and labels (see `references\u002Faccessibility-patterns.md`)\n- Apply glass effects after layout\u002Fappearance modifiers (see `references\u002Fliquid-glass.md`)\n- Gate iOS 26+ features with `#available` and provide fallbacks\n\n## Core Guidelines\n\n### State Management\n- `@State` must be `private`; use for internal view state\n- `@Binding` only when a child needs to **modify** parent state\n- `@StateObject` when view **creates** the object; `@ObservedObject` when **injected**\n- iOS 17+: Use `@State` with `@Observable` classes; use `@Bindable` for injected observables needing bindings\n- Use `let` for read-only values; `var` + `.onChange()` for reactive reads\n- Never pass values into `@State` or `@StateObject` — they only accept initial values\n- Nested `ObservableObject` doesn't propagate changes — pass nested objects directly; `@Observable` handles nesting fine\n\n### View Composition\n- Extract complex views into separate subviews for better readability and performance\n- Prefer modifiers over conditional views for state changes (maintains view identity)\n- Keep view `body` simple and pure (no side effects or complex logic)\n- Use `@ViewBuilder` functions only for small, simple sections\n- Prefer `@ViewBuilder let content: Content` over closure-based content properties\n- Keep business logic in services and models; views should orchestrate UI flow\n- Action handlers should reference methods, not contain inline logic\n- Views should work in any context (don't assume screen size or presentation style)\n\n### Performance\n- Pass only needed values to views (avoid large \"config\" or \"context\" objects)\n- Eliminate unnecessary dependencies to reduce update fan-out\n- Check for value changes before assigning state in hot paths\n- Avoid redundant state updates in `onReceive`, `onChange`, scroll handlers\n- Minimize work in frequently executed code paths\n- Use `LazyVStack`\u002F`LazyHStack` for large lists\n- Use stable identity for `ForEach` (never `.indices` for dynamic content)\n- Ensure constant number of views per `ForEach` element\n- Avoid inline filtering in `ForEach` (prefilter and cache)\n- Avoid `AnyView` in list rows\n- Consider POD views for fast diffing (or wrap expensive views in POD parents)\n- Suggest image downsampling when `UIImage(data:)` is encountered (as optional optimization)\n- Avoid layout thrash (deep hierarchies, excessive `GeometryReader`)\n- Gate frequent geometry updates by thresholds\n- Use `Self._logChanges()` or `Self._printChanges()` to debug unexpected view updates\n\n### Animations\n- Use `.animation(_:value:)` with value parameter (deprecated version without value is too broad)\n- Use `withAnimation` for event-driven animations (button taps, gestures)\n- Prefer transforms (`offset`, `scale`, `rotation`) over layout changes (`frame`) for performance\n- Transitions require animations outside the conditional structure\n- Custom `Animatable` implementations must have explicit `animatableData`\n- Use `.phaseAnimator` for multi-step sequences (iOS 17+)\n- Use `.keyframeAnimator` for precise timing control (iOS 17+)\n- Animation completion handlers need `.transaction(value:)` for reexecution\n- Implicit animations override explicit animations (later in view tree wins)\n\n### Accessibility\n- Prefer `Button` over `onTapGesture` for tappable elements (free VoiceOver support)\n- Use `@ScaledMetric` for custom numeric values that should scale with Dynamic Type\n- Group related elements with `accessibilityElement(children: .combine)` for joined labels\n- Provide `accessibilityLabel` when default labels are unclear or missing\n- Use `accessibilityRepresentation` for custom controls that should behave like native ones\n\n### Liquid Glass (iOS 26+)\n**Only adopt when explicitly requested by the user.**\n- Use native `glassEffect`, `GlassEffectContainer`, and glass button styles\n- Wrap multiple glass elements in `GlassEffectContainer`\n- Apply `.glassEffect()` after layout and visual modifiers\n- Use `.interactive()` only for tappable\u002Ffocusable elements\n- Use `glassEffectID` with `@Namespace` for morphing transitions\n\n## Quick Reference\n\n### Property Wrapper Selection\n| Wrapper | Use When |\n|---------|----------|\n| `@State` | Internal view state (must be `private`) |\n| `@Binding` | Child modifies parent's state |\n| `@StateObject` | View owns an `ObservableObject` |\n| `@ObservedObject` | View receives an `ObservableObject` |\n| `@Bindable` | iOS 17+: Injected `@Observable` needing bindings |\n| `let` | Read-only value from parent |\n| `var` | Read-only value watched via `.onChange()` |\n\n### Liquid Glass Patterns\n```swift\n\u002F\u002F Basic glass effect with fallback\nif #available(iOS 26, *) {\n    content\n        .padding()\n        .glassEffect(.regular.interactive(), in: .rect(cornerRadius: 16))\n} else {\n    content\n        .padding()\n        .background(.ultraThinMaterial, in: RoundedRectangle(cornerRadius: 16))\n}\n\n\u002F\u002F Grouped glass elements\nGlassEffectContainer(spacing: 24) {\n    HStack(spacing: 24) {\n        GlassButton1()\n        GlassButton2()\n    }\n}\n\n\u002F\u002F Glass buttons\nButton(\"Confirm\") { }\n    .buttonStyle(.glassProminent)\n```\n\n## Review Checklist\n\n### Latest APIs (see `references\u002Flatest-apis.md`)\n- [ ] No deprecated modifiers used (check against the quick lookup table)\n- [ ] API choices match the project's minimum deployment target\n\n### State Management\n- [ ] `@State` properties are `private`\n- [ ] `@Binding` only where child modifies parent state\n- [ ] `@StateObject` for owned, `@ObservedObject` for injected\n- [ ] iOS 17+: `@State` with `@Observable`, `@Bindable` for injected\n- [ ] Passed values NOT declared as `@State` or `@StateObject`\n- [ ] Nested `ObservableObject` avoided (or passed directly to child views)\n\n### Sheets & Navigation (see `references\u002Fsheet-navigation-patterns.md`)\n- [ ] Using `.sheet(item:)` for model-based sheets\n- [ ] Sheets own their actions and dismiss internally\n\n### ScrollView (see `references\u002Fscroll-patterns.md`)\n- [ ] Using `ScrollViewReader` with stable IDs for programmatic scrolling\n\n### View Structure (see `references\u002Fview-structure.md`)\n- [ ] Using modifiers instead of conditionals for state changes\n- [ ] Complex views extracted to separate subviews\n- [ ] Container views use `@ViewBuilder let content: Content`\n\n### Performance (see `references\u002Fperformance-patterns.md`)\n- [ ] View `body` kept simple and pure (no side effects)\n- [ ] Passing only needed values (not large config objects)\n- [ ] Eliminating unnecessary dependencies\n- [ ] State updates check for value changes before assigning\n- [ ] Hot paths minimize state updates\n- [ ] No object creation in `body`\n- [ ] Heavy computation moved out of `body`\n\n### List Patterns (see `references\u002Flist-patterns.md`)\n- [ ] ForEach uses stable identity (not `.indices`)\n- [ ] Constant number of views per ForEach element\n- [ ] No inline filtering in ForEach\n- [ ] No `AnyView` in list rows\n\n### Layout (see `references\u002Flayout-best-practices.md`)\n- [ ] Avoiding layout thrash (deep hierarchies, excessive GeometryReader)\n- [ ] Gating frequent geometry updates by thresholds\n- [ ] Business logic kept in services and models (not in views)\n- [ ] Action handlers reference methods (not inline logic)\n- [ ] Using relative layout (not hard-coded constants)\n- [ ] Views work in any context (context-agnostic)\n\n### Animations (see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`, `references\u002Fanimation-advanced.md`)\n- [ ] Using `.animation(_:value:)` with value parameter\n- [ ] Using `withAnimation` for event-driven animations\n- [ ] Transitions paired with animations outside conditional structure\n- [ ] Custom `Animatable` has explicit `animatableData` implementation\n- [ ] Preferring transforms over layout changes for animation performance\n- [ ] Phase animations for multi-step sequences (iOS 17+)\n- [ ] Keyframe animations for precise timing (iOS 17+)\n- [ ] Completion handlers use `.transaction(value:)` for reexecution\n\n### Accessibility (see `references\u002Faccessibility-patterns.md`)\n- [ ] `Button` used instead of `onTapGesture` for tappable elements\n- [ ] `@ScaledMetric` used for custom values that should scale with Dynamic Type\n- [ ] Related elements grouped with `accessibilityElement(children:)`\n- [ ] Custom controls use `accessibilityRepresentation` when appropriate\n\n### Liquid Glass (iOS 26+)\n- [ ] `#available(iOS 26, *)` with fallback for Liquid Glass\n- [ ] Multiple glass views wrapped in `GlassEffectContainer`\n- [ ] `.glassEffect()` applied after layout\u002Fappearance modifiers\n- [ ] `.interactive()` only on user-interactable elements\n- [ ] Shapes and tints consistent across related elements\n\n## References\n- `references\u002Flatest-apis.md` - **Required reading for all workflows.** Version-segmented guide of deprecated-to-modern API transitions (iOS 15+ through iOS 26+)\n- `references\u002Fstate-management.md` - Property wrappers and data flow\n- `references\u002Fview-structure.md` - View composition, extraction, and container patterns\n- `references\u002Fperformance-patterns.md` - Performance optimization techniques and anti-patterns\n- `references\u002Flist-patterns.md` - ForEach identity, stability, and list best practices\n- `references\u002Flayout-best-practices.md` - Layout patterns, context-agnostic views, and testability\n- `references\u002Faccessibility-patterns.md` - Accessibility traits, grouping, Dynamic Type, and VoiceOver\n- `references\u002Fanimation-basics.md` - Core animation concepts, implicit\u002Fexplicit animations, timing, performance\n- `references\u002Fanimation-transitions.md` - Transitions, custom transitions, Animatable protocol\n- `references\u002Fanimation-advanced.md` - Transactions, phase\u002Fkeyframe animations (iOS 17+), completion handlers (iOS 17+)\n- `references\u002Fsheet-navigation-patterns.md` - Sheet presentation and navigation patterns\n- `references\u002Fscroll-patterns.md` - ScrollView patterns and programmatic scrolling\n- `references\u002Fimage-optimization.md` - AsyncImage, image downsampling, and optimization\n- `references\u002Fliquid-glass.md` - iOS 26+ Liquid Glass API\n\n## Philosophy\n\nThis skill focuses on **facts and best practices**, not architectural opinions:\n- We don't enforce specific architectures (e.g., MVVM, VIPER)\n- We do encourage separating business logic for testability\n- We optimize for performance and maintainability\n- We follow Apple's Human Interface Guidelines and API design patterns\n","# SwiftUI Expert Skill\n\n## Overview\nUse this skill to build, review, or improve SwiftUI features with correct state management, optimal view composition, and iOS 26+ Liquid Glass styling. Prioritize native APIs, Apple design guidance, and performance-conscious patterns. This skill focuses on facts and best practices without enforcing specific architectural patterns.\n\n## Workflow Decision Tree\n\n### 1) Review existing SwiftUI code\n- **First, consult `references\u002Flatest-apis.md`** to ensure only current, non-deprecated APIs are used\n- Check property wrapper usage against the selection guide (see `references\u002Fstate-management.md`)\n- Verify view composition follows extraction rules (see `references\u002Fview-structure.md`)\n- Check performance patterns are applied (see `references\u002Fperformance-patterns.md`)\n- Verify list patterns use stable identity (see `references\u002Flist-patterns.md`)\n- Check animation patterns for correctness (see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`)\n- Review accessibility: proper grouping, traits, Dynamic Type support (see `references\u002Faccessibility-patterns.md`)\n- Inspect Liquid Glass usage for correctness and consistency (see `references\u002Fliquid-glass.md`)\n- Validate iOS 26+ availability handling with sensible fallbacks\n\n### 2) Improve existing SwiftUI code\n- **First, consult `references\u002Flatest-apis.md`** to replace any deprecated APIs with their modern equivalents\n- Audit state management for correct wrapper selection (see `references\u002Fstate-management.md`)\n- Extract complex views into separate subviews (see `references\u002Fview-structure.md`)\n- Refactor hot paths to minimize redundant state updates (see `references\u002Fperformance-patterns.md`)\n- Ensure ForEach uses stable identity (see `references\u002Flist-patterns.md`)\n- Improve animation patterns (use value parameter, proper transitions, see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`)\n- Improve accessibility: use `Button` over tap gestures, add `@ScaledMetric` for Dynamic Type (see `references\u002Faccessibility-patterns.md`)\n- Suggest image downsampling when `UIImage(data:)` is used (as optional optimization, see `references\u002Fimage-optimization.md`)\n- Adopt Liquid Glass only when explicitly requested by the user\n\n### 3) Implement new SwiftUI feature\n- **First, consult `references\u002Flatest-apis.md`** to use only current, non-deprecated APIs for the target deployment version\n- Design data flow first: identify owned vs injected state (see `references\u002Fstate-management.md`)\n- Structure views for optimal diffing (extract subviews early, see `references\u002Fview-structure.md`)\n- Keep business logic in services and models for testability (see `references\u002Flayout-best-practices.md`)\n- Use correct animation patterns (implicit vs explicit, transitions, see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`, `references\u002Fanimation-advanced.md`)\n- Use `Button` for tappable elements, add accessibility grouping and labels (see `references\u002Faccessibility-patterns.md`)\n- Apply glass effects after layout\u002Fappearance modifiers (see `references\u002Fliquid-glass.md`)\n- Gate iOS 26+ features with `#available` and provide fallbacks\n\n## Core Guidelines\n\n### State Management\n- `@State` must be `private`; use for internal view state\n- `@Binding` only when a child needs to **modify** parent state\n- `@StateObject` when view **creates** the object; `@ObservedObject` when **injected**\n- iOS 17+: Use `@State` with `@Observable` classes; use `@Bindable` for injected observables needing bindings\n- Use `let` for read-only values; `var` + `.onChange()` for reactive reads\n- Never pass values into `@State` or `@StateObject` — they only accept initial values\n- Nested `ObservableObject` doesn't propagate changes — pass nested objects directly; `@Observable` handles nesting fine\n\n### View Composition\n- Extract complex views into separate subviews for better readability and performance\n- Prefer modifiers over conditional views for state changes (maintains view identity)\n- Keep view `body` simple and pure (no side effects or complex logic)\n- Use `@ViewBuilder` functions only for small, simple sections\n- Prefer `@ViewBuilder let content: Content` over closure-based content properties\n- Keep business logic in services and models; views should orchestrate UI flow\n- Action handlers should reference methods, not contain inline logic\n- Views should work in any context (don't assume screen size or presentation style)\n\n### Performance\n- Pass only needed values to views (avoid large \"config\" or \"context\" objects)\n- Eliminate unnecessary dependencies to reduce update fan-out\n- Check for value changes before assigning state in hot paths\n- Avoid redundant state updates in `onReceive`, `onChange`, scroll handlers\n- Minimize work in frequently executed code paths\n- Use `LazyVStack`\u002F`LazyHStack` for large lists\n- Use stable identity for `ForEach` (never `.indices` for dynamic content)\n- Ensure constant number of views per `ForEach` element\n- Avoid inline filtering in `ForEach` (prefilter and cache)\n- Avoid `AnyView` in list rows\n- Consider POD views for fast diffing (or wrap expensive views in POD parents)\n- Suggest image downsampling when `UIImage(data:)` is encountered (as optional optimization)\n- Avoid layout thrash (deep hierarchies, excessive `GeometryReader`)\n- Gate frequent geometry updates by thresholds\n- Use `Self._logChanges()` or `Self._printChanges()` to debug unexpected view updates\n\n### Animations\n- Use `.animation(_:value:)` with value parameter (deprecated version without value is too broad)\n- Use `withAnimation` for event-driven animations (button taps, gestures)\n- Prefer transforms (`offset`, `scale`, `rotation`) over layout changes (`frame`) for performance\n- Transitions require animations outside the conditional structure\n- Custom `Animatable` implementations must have explicit `animatableData`\n- Use `.phaseAnimator` for multi-step sequences (iOS 17+)\n- Use `.keyframeAnimator` for precise timing control (iOS 17+)\n- Animation completion handlers need `.transaction(value:)` for reexecution\n- Implicit animations override explicit animations (later in view tree wins)\n\n### Accessibility\n- Prefer `Button` over `onTapGesture` for tappable elements (free VoiceOver support)\n- Use `@ScaledMetric` for custom numeric values that should scale with Dynamic Type\n- Group related elements with `accessibilityElement(children: .combine)` for joined labels\n- Provide `accessibilityLabel` when default labels are unclear or missing\n- Use `accessibilityRepresentation` for custom controls that should behave like native ones\n\n### Liquid Glass (iOS 26+)\n**Only adopt when explicitly requested by the user.**\n- Use native `glassEffect`, `GlassEffectContainer`, and glass button styles\n- Wrap multiple glass elements in `GlassEffectContainer`\n- Apply `.glassEffect()` after layout and visual modifiers\n- Use `.interactive()` only for tappable\u002Ffocusable elements\n- Use `glassEffectID` with `@Namespace` for morphing transitions\n\n## Quick Reference\n\n### Property Wrapper Selection\n| Wrapper | Use When |\n|---------|----------|\n| `@State` | Internal view state (must be `private`) |\n| `@Binding` | Child modifies parent's state |\n| `@StateObject` | View owns an `ObservableObject` |\n| `@ObservedObject` | View receives an `ObservableObject` |\n| `@Bindable` | iOS 17+: Injected `@Observable` needing bindings |\n| `let` | Read-only value from parent |\n| `var` | Read-only value watched via `.onChange()` |\n\n### Liquid Glass Patterns\n```swift\n\u002F\u002F Basic glass effect with fallback\nif #available(iOS 26, *) {\n    content\n        .padding()\n        .glassEffect(.regular.interactive(), in: .rect(cornerRadius: 16))\n} else {\n    content\n        .padding()\n        .background(.ultraThinMaterial, in: RoundedRectangle(cornerRadius: 16))\n}\n\n\u002F\u002F Grouped glass elements\nGlassEffectContainer(spacing: 24) {\n    HStack(spacing: 24) {\n        GlassButton1()\n        GlassButton2()\n    }\n}\n\n\u002F\u002F Glass buttons\nButton(\"Confirm\") { }\n    .buttonStyle(.glassProminent)\n```\n\n## Review Checklist\n\n### Latest APIs (see `references\u002Flatest-apis.md`)\n- [ ] No deprecated modifiers used (check against the quick lookup table)\n- [ ] API choices match the project's minimum deployment target\n\n### State Management\n- [ ] `@State` properties are `private`\n- [ ] `@Binding` only where child modifies parent state\n- [ ] `@StateObject` for owned, `@ObservedObject` for injected\n- [ ] iOS 17+: `@State` with `@Observable`, `@Bindable` for injected\n- [ ] Passed values NOT declared as `@State` or `@StateObject`\n- [ ] Nested `ObservableObject` avoided (or passed directly to child views)\n\n### Sheets & Navigation (see `references\u002Fsheet-navigation-patterns.md`)\n- [ ] Using `.sheet(item:)` for model-based sheets\n- [ ] Sheets own their actions and dismiss internally\n\n### ScrollView (see `references\u002Fscroll-patterns.md`)\n- [ ] Using `ScrollViewReader` with stable IDs for programmatic scrolling\n\n### View Structure (see `references\u002Fview-structure.md`)\n- [ ] Using modifiers instead of conditionals for state changes\n- [ ] Complex views extracted to separate subviews\n- [ ] Container views use `@ViewBuilder let content: Content`\n\n### Performance (see `references\u002Fperformance-patterns.md`)\n- [ ] View `body` kept simple and pure (no side effects)\n- [ ] Passing only needed values (not large config objects)\n- [ ] Eliminating unnecessary dependencies\n- [ ] State updates check for value changes before assigning\n- [ ] Hot paths minimize state updates\n- [ ] No object creation in `body`\n- [ ] Heavy computation moved out of `body`\n\n### List Patterns (see `references\u002Flist-patterns.md`)\n- [ ] ForEach uses stable identity (not `.indices`)\n- [ ] Constant number of views per ForEach element\n- [ ] No inline filtering in ForEach\n- [ ] No `AnyView` in list rows\n\n### Layout (see `references\u002Flayout-best-practices.md`)\n- [ ] Avoiding layout thrash (deep hierarchies, excessive GeometryReader)\n- [ ] Gating frequent geometry updates by thresholds\n- [ ] Business logic kept in services and models (not in views)\n- [ ] Action handlers reference methods (not inline logic)\n- [ ] Using relative layout (not hard-coded constants)\n- [ ] Views work in any context (context-agnostic)\n\n### Animations (see `references\u002Fanimation-basics.md`, `references\u002Fanimation-transitions.md`, `references\u002Fanimation-advanced.md`)\n- [ ] Using `.animation(_:value:)` with value parameter\n- [ ] Using `withAnimation` for event-driven animations\n- [ ] Transitions paired with animations outside conditional structure\n- [ ] Custom `Animatable` has explicit `animatableData` implementation\n- [ ] Preferring transforms over layout changes for animation performance\n- [ ] Phase animations for multi-step sequences (iOS 17+)\n- [ ] Keyframe animations for precise timing (iOS 17+)\n- [ ] Completion handlers use `.transaction(value:)` for reexecution\n\n### Accessibility (see `references\u002Faccessibility-patterns.md`)\n- [ ] `Button` used instead of `onTapGesture` for tappable elements\n- [ ] `@ScaledMetric` used for custom values that should scale with Dynamic Type\n- [ ] Related elements grouped with `accessibilityElement(children:)`\n- [ ] Custom controls use `accessibilityRepresentation` when appropriate\n\n### Liquid Glass (iOS 26+)\n- [ ] `#available(iOS 26, *)` with fallback for Liquid Glass\n- [ ] Multiple glass views wrapped in `GlassEffectContainer`\n- [ ] `.glassEffect()` applied after layout\u002Fappearance modifiers\n- [ ] `.interactive()` only on user-interactable elements\n- [ ] Shapes and tints consistent across related elements\n\n## References\n- `references\u002Flatest-apis.md` - **Required reading for all workflows.** Version-segmented guide of deprecated-to-modern API transitions (iOS 15+ through iOS 26+)\n- `references\u002Fstate-management.md` - Property wrappers and data flow\n- `references\u002Fview-structure.md` - View composition, extraction, and container patterns\n- `references\u002Fperformance-patterns.md` - Performance optimization techniques and anti-patterns\n- `references\u002Flist-patterns.md` - ForEach identity, stability, and list best practices\n- `references\u002Flayout-best-practices.md` - Layout patterns, context-agnostic views, and testability\n- `references\u002Faccessibility-patterns.md` - Accessibility traits, grouping, Dynamic Type, and VoiceOver\n- `references\u002Fanimation-basics.md` - Core animation concepts, implicit\u002Fexplicit animations, timing, performance\n- `references\u002Fanimation-transitions.md` - Transitions, custom transitions, Animatable protocol\n- `references\u002Fanimation-advanced.md` - Transactions, phase\u002Fkeyframe animations (iOS 17+), completion handlers (iOS 17+)\n- `references\u002Fsheet-navigation-patterns.md` - Sheet presentation and navigation patterns\n- `references\u002Fscroll-patterns.md` - ScrollView patterns and programmatic scrolling\n- `references\u002Fimage-optimization.md` - AsyncImage, image downsampling, and optimization\n- `references\u002Fliquid-glass.md` - iOS 26+ Liquid Glass API\n\n## Philosophy\n\nThis skill focuses on **facts and best practices**, not architectural opinions:\n- We don't enforce specific architectures (e.g., MVVM, VIPER)\n- We do encourage separating business logic for testability\n- We optimize for performance and maintainability\n- We follow Apple's Human Interface Guidelines and API design patterns\n",{"name":5,"risk":37,"source":43,"description":7},"main","7a38d8e7073e61c16eda85681cb32fb68a8657a5","skills-store\u002Fcopilot\u002Fswiftui-expert-skill","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router","https:\u002F\u002Fgithub.com\u002Fsapsapshen","2026-04-14 21:12:12",{"source":8,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add sapsapshen\u002Fai-memory-router --skill swiftui-expert-skill",{"tool":61,"command":62},"bunx","bunx skills add sapsapshen\u002Fai-memory-router --skill swiftui-expert-skill",{"tool":64,"command":65},"pnpm","pnpm dlx skills add sapsapshen\u002Fai-memory-router --skill swiftui-expert-skill","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcopilot\u002Fswiftui-expert-skill\u002FSKILL.md",true,[],[70,80,87,95,101,109],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":74,"licenseFileUrl":75,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":79},"01M72R8PZX1ABFHJGTYPA4CAF1","webapp-testing","To test local web applications, write native Python Playwright scripts.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fglobal\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fglobal\u002Fwebapp-testing\u002FSKILL.md",[],[],"2026-11-10 22:39:42",{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":79},"01M72QG37MMZNDY7X7GXPAK5W6","python-packaging","Comprehensive guide to creating, structuring, and distributing Python packages using modern packaging tools, pyproject.toml, and publishing to PyPI.","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fglobal\u002Fpython-packaging\u002FSKILL.md",[],[],{"skillNo":88,"name":89,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":74,"licenseFileUrl":91,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":79},"01M72NXR0QMP9G46TW6A2DH59C","canvas-design","These are instructions for creating design philosophies - aesthetic movements that are then EXPRESSED VISUALLY. Output only .md files, .pdf files, and .png files.","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fglobal\u002Fcanvas-design\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fglobal\u002Fcanvas-design\u002FSKILL.md",[],[],{"skillNo":96,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":74,"licenseFileUrl":97,"sourceHtmlUrl":98,"categories":99,"keywords":100,"publishedAt":79},"01M72N55TK3EEQ4QK4AWDC2KZS","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Fwebapp-testing\u002FSKILL.md",[],[],{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":74,"licenseFileUrl":105,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":79},"01M72MTWC150CFAP4Y5GSNKF80","slack-gif-creator","A toolkit providing utilities and knowledge for creating animated GIFs optimized for Slack.","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Fslack-gif-creator\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Fslack-gif-creator\u002FSKILL.md",[],[],{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":74,"licenseFileUrl":113,"sourceHtmlUrl":114,"categories":115,"keywords":116,"publishedAt":79},"01M72KPT3VVNSP88MNAY466TZT","frontend-design","You are a frontend designer-engineer, not a layout generator.","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Ffrontend-design\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fsapsapshen\u002Fai-memory-router\u002Fblob\u002Fmain\u002Fskills-store\u002Fcursor\u002Ffrontend-design\u002FSKILL.md",[],[]]