swiftdata

Provide SwiftData API references for models, contexts, queries, and migrations.

Updated Apr 27, 2026
One-click install
npx skills add https://github.com/annurdien/skills --skill swiftdata-annurdien
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: swiftdata
Source: https://github.com/annurdien/skills/tree/main/swiftdata
Command: npx skills add https://github.com/annurdien/skills --skill swiftdata-annurdien

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Quickly locate and understand SwiftData API references for models, contexts, queries, and migrations, so you can implement persistence and data fetching without hunting through scattered docs.

Core Features & Use Cases

  • Centralized references for SwiftData macros and core APIs (@Model, ModelContext, @Query, and migrations).
  • Easy navigation to model lifecycle, data persistence, and querying concepts.
  • Use Case: when building SwiftUI apps that persist data, you can consult the references to implement your data layer correctly.

Quick Start

Look up the SwiftData API references in the provided files to start implementing a SwiftData-backed data model.

Frequently Asked Questions about swiftdata

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

FAQPage Schema
How do I use the @Model macro for SwiftData persistence?

The @Model macro in SwiftData defines your data schema for persistence. You can consult the centralized API references to understand model lifecycles and implement your data layer correctly without hunting through scattered docs.

What is the best way to query data using @Query in SwiftData?

The best way to query data in SwiftData is by using the @Query macro. This skill provides quick access to @Query API references, enabling you to implement data fetching in your SwiftUI apps accurately.

How do I handle SwiftData schema migrations?

SwiftData schema migrations are handled using specific migration APIs. This skill provides quick access to migration references, allowing you to manage model lifecycle changes and implement data persistence safely.

Does this provide API references for ModelContext in SwiftData?

Yes, it provides centralized SwiftData API references for ModelContext. You can navigate these references to answer implementation questions regarding data persistence and model lifecycles in real projects.

Why use a SwiftData API reference when building SwiftUI apps?

A SwiftData API reference helps you quickly locate precise guidance for models, contexts, and queries. It enables you to implement your SwiftUI app's data layer correctly without searching through scattered documentation.