What problem does it solve?
This Skill provides a comprehensive guide to building robust and secure backend operations (queries and actions) in Wasp applications. It simplifies client-server communication, enforces best practices, and leverages Wasp's auto-invalidation, saving significant development time.
Core Features & Use Cases
- Standardized Operation Patterns: Offers ready-to-use templates for creating, reading, updating, and deleting data, including auth checks, validation, and permission handling.
- Auto-Invalidation Magic: Explains how to leverage Wasp's automatic cache invalidation, eliminating the need for manual cache management in the client.
- Type-Safe Development: Emphasizes critical type annotations for
context.entities access, preventing runtime errors and improving code reliability.
- Use Case: Create a new Wasp query
getTasks that fetches all tasks for the authenticated user, and an action createTask that adds a new task. This Skill ensures both operations are type-safe, include auth checks, and that getTasks automatically refetches after createTask completes.
Quick Start
Create a new Wasp query getTasks that fetches all tasks for the authenticated user. Ensure it includes an auth check and returns a list of Task entities.