preview-coverage

Validate SwiftUI preview coverage for all Views in MeetingAssistantCoreUI.

Updated Dec 25, 2025
One-click install
npx skills add https://github.com/mourato/prisma --skill preview-coverage
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: preview-coverage
Source: https://github.com/mourato/prisma/tree/main/.agents/skills/preview-coverage
Command: npx skills add https://github.com/mourato/prisma --skill preview-coverage

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill ensures that all SwiftUI Views within the MeetingAssistantCoreUI have adequate preview coverage, preventing regressions and improving UI quality.

Core Features & Use Cases

  • Enforces Preview Standards: Guarantees that every SwiftUI View has at least one preview.
  • Promotes State Testing: Encourages multiple previews for different UI states (e.g., loading, error, success).
  • Use Case: Before merging a new UI component, use this skill to automatically verify that all its states are covered by SwiftUI previews, ensuring a robust user experience.

Quick Start

Run the preview check command to validate SwiftUI preview coverage.

Frequently Asked Questions about preview-coverage

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

FAQPage Schema
How do I check if my SwiftUI Views have adequate preview coverage?

To check SwiftUI preview coverage, you can run a validation script that enforces every View has at least one preview. This ensures all UI components are adequately tested to prevent regressions.

What states should I cover when creating SwiftUI previews for a View?

When creating SwiftUI previews, you should cover multiple meaningful states such as loading, error, and success. Testing these distinct states ensures a robust user experience and verifies interactive control behavior.

Can I use this validation tool with any SwiftUI project or only specific ones?

This validation tool is specifically designed to validate preview coverage for SwiftUI Views within the MeetingAssistantCoreUI project. It enforces standards for creating and maintaining previews in that context.

Does SwiftUI preview validation check keyboard and focus behavior?

Yes, SwiftUI preview validation ensures verification of keyboard and focus behavior for interactive controls in previews. It also enforces requirements for avoiding side effects during these checks.

Why do I need multiple SwiftUI previews for different UI states?

You need multiple SwiftUI previews for different UI states to prevent regressions and improve UI quality. This practice guarantees comprehensive validation of loading, error, and success conditions before merging components.

What should I avoid when setting up SwiftUI previews for interactive controls?

When setting up SwiftUI previews for interactive controls, you should avoid introducing side effects. The validation enforces strict standards to ensure previews remain isolated and do not trigger unintended state mutations.