repositories

Community

Clean data access with the Repository Pattern.

Authormoasq
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill addresses the challenge of tightly coupled data access logic within applications, making code harder to test, maintain, and scale. It enforces a clean separation between data sources and business logic.

Core Features & Use Cases

  • Protocol-Based Data Access: Define data access contracts using Swift protocols, ensuring ViewModels depend on abstractions, not concrete implementations.
  • DTO-to-Domain Mapping: Clearly separates database schema representations (DTOs) from your application's domain models, facilitating type safety and cleaner code.
  • Layer Separation: Enforces a strict data flow (Supabase API → DTO → Repository → Domain Model → ViewModel → View), promoting modularity and testability.
  • Use Case: When building a new feature that requires fetching user data, use this Skill to define a UserRepository protocol, implement it against a Supabase backend, and inject it into your ViewModel, ensuring your UI layer remains independent of the data source.

Quick Start

Implement the repository pattern for a new 'Product' entity by defining a ProductRepository protocol and a SupabaseProductRepository concrete implementation.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: repositories
Download link: https://github.com/moasq/nanowave/archive/main.zip#repositories

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.