Chuyển đến nội dung
Skillpedia
Ứng dụng di động48k · #6068

update-swiftui-apis

Skill này làm gì

Công cụ này kiểm tra tài liệu chính thức của Apple về các phần đã lỗi thời (deprecated) trong SwiftUI và cập nhật chúng bằng phiên bản mới nhất. Nó giúp code của bạn luôn hiện đại và tương thích.

Khi nào nên dùng

  • ✓Khi bạn muốn đảm bảo code SwiftUI đang dùng các API mới nhất.
  • ✓Sau khi có phiên bản iOS hoặc Xcode mới.
  • ✓Khi bạn thấy cảnh báo về API đã lỗi thời trong dự án.

Liên kết skill

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/update-swiftui-apis/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/update-swiftui-apis/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Kiểm tra các API SwiftUI đã lỗi thời và cập nhật chúng bằng phiên bản mới nhất.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Công cụ tìm trong tài liệu Apple các API được đánh dấu là “deprecated” và tìm các thay thế hiện đại. Sau đó nó cập nhật một file tham chiếu với thông tin này.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Update SwiftUI APIs

When to Use

Use this skill when you need scan Apple's SwiftUI documentation for deprecated APIs and update the SwiftUI Expert Skill with modern replacements. Use when asked to "update latest APIs", "refresh deprecated SwiftUI APIs", "check for new SwiftUI deprecations", "scan for API changes", or after a new iOS/Xcode...

Systematically scan Apple's developer documentation via the Sosumi MCP, identify deprecated SwiftUI APIs and their modern replacements, and update swiftui-expert-skill/references/latest-apis.md.

Prerequisites

  • Sosumi MCP must be enabled and available (provides searchAppleDocumentation, fetchAppleDocumentation, fetchAppleVideoTranscript, fetchExternalDocumentation)
  • Write access to this repository (or a fork)

Workflow

1. Understand current coverage

Read swiftui-expert-skill/references/latest-apis.md to understand:

  • Which deprecated-to-modern transitions are already documented
  • The version segments in use (iOS 15+, 16+, 17+, 18+, 26+)
  • The Quick Lookup Table at the bottom

2. Load the scan manifest

Read references/scan-manifest.md (relative to this skill). It contains the categorized list of API areas, documentation paths, search queries, and WWDC video paths to scan.

3. Scan Apple documentation

For each category in the manifest:

  1. Call searchAppleDocumentation with the listed queries to discover relevant pages.
  2. Call fetchAppleDocumentation with specific documentation paths to get full API details.
  3. Look for deprecation notices, "Deprecated" labels, and "Use ... instead" guidance.
  4. Note the iOS version where the modern replacement became available.
  5. Optionally call fetchAppleVideoTranscript for WWDC sessions that announce API changes.

Batch related searches together for efficiency. Focus on finding new deprecations not yet in latest-apis.md.

4. Compare and identify changes

Compare findings against existing entries. Categorize results:

  • New deprecations: APIs not yet documented in latest-apis.md
  • Corrections: Existing entries that need updating (wrong version, better replacement available)
  • New version segments: If a new iOS version introduces deprecations, add a new section

5. Update latest-apis.md

Follow the established format exactly. Each entry must include:

Section placement -- place under the correct version segment:

  • "Always Use (iOS 15+)" for long-deprecated APIs
  • "When Targeting iOS 16+" / "17+" / "18+" / "26+" for version-gated changes

Entry format:

**Always use `modernAPI()` instead of `deprecatedAPI()`.**

\```swift
// Modern
View()
    .modernAPI()

// Deprecated
View()
    .deprecatedAPI()
\```

Quick Lookup Table -- add a row at the bottom of the file:

| `deprecatedAPI()` | `modernAPI()` | iOS XX+ |

Keep the attribution line at the top of the file:

Based on a comparison of Apple's documentation using the Sosumi MCP, we found the latest recommended APIs to use.

6. Open a pull request

  1. Create a branch from main named update/latest-apis-YYYY-MM (use current year and month).
  2. Commit changes to swiftui-expert-skill/references/latest-apis.md.
  3. Open a PR via gh pr create with:
    • Title: "Update latest SwiftUI APIs (Month Year)"
    • Body: Summary of new/changed entries, attribution to Sosumi MCP

Sosumi MCP Tool Reference

Tool Parameters Returns
searchAppleDocumentation query (string) JSON with results[] containing title, url, description, breadcrumbs, tags, type
fetchAppleDocumentation path (string, e.g. /documentation/swiftui/view/foregroundstyle(_:)) Markdown documentation content
fetchAppleVideoTranscript path (string, e.g. /videos/play/wwdc2025/10133) Markdown transcript
fetchExternalDocumentation url (string, full https URL) Markdown documentation content

Tips

  • Start broad with searchAppleDocumentation queries, then drill into specific paths with fetchAppleDocumentation.
  • Apple's deprecation docs typically say "Deprecated" in the page and link to the replacement.
  • WWDC "What's new in SwiftUI" sessions are the best source for newly introduced replacements.
  • When unsure about the exact iOS version for a deprecation, verify by checking the "Availability" section in the fetched documentation.

…

Câu hỏi thường gặp

“Deprecated” nghĩa là gì?

Nghĩa là một hàm hoặc đoạn code không còn được khuyến nghị dùng, vì sẽ bị gỡ bỏ trong tương lai hoặc đã có phiên bản tốt hơn.

Tôi có cần kiến thức kỹ thuật để dùng không?

Không, bạn chỉ cần yêu cầu AI kiểm tra cập nhật. Công cụ làm phần việc nặng nhọc ở phía sau.

“Sosumi MCP” là gì?

Đây là công cụ nội bộ mà AI dùng để truy cập và tìm kiếm trong tài liệu của Apple.

Chi tiết

Mô tả gốc của tác giả

Scan Apple's SwiftUI documentation for deprecated APIs and update the SwiftUI Expert Skill with modern replacements.

repo: sickn33/agentic-awesome-skills

Độ phổ biến

Sao GitHub
48k
Vị trí xếp hạng
#6068
Giấy phép
MIT
Cập nhật
15/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự