task-template-builder

Documents Task Template Builder architecture for schema, drafts, drag-and-drop, and validation.

1|Updated Jan 2, 2025
One-click install
npx skills add https://github.com/allenlin90/eridu-services --skill task-template-builder
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: task-template-builder
Source: https://github.com/allenlin90/eridu-services/tree/main/.agent/skills/task-template-builder
Command: npx skills add https://github.com/allenlin90/eridu-services --skill task-template-builder

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This guide clarifies how to keep frontend and backend task-template schemas in sync, eliminates duplicated validation logic, and provides a clear blueprint for drafting, dragging, and validating templates across the stack.

Core Features & Use Cases

  • Schema alignment using a shared Zod schema from @eridu/api-types to enforce a single source of truth.
  • Draft storage in IndexedDB using idb-keyval to prevent data loss during editing.
  • Drag-and-Drop support via @dnd-kit with stable IDs to reorder fields and templates.
  • Advanced validation and payload transformation to ensure API compatibility and data integrity.

Quick Start

Describe a task template using the builder by aligning fields to the shared schema, enabling draft storage, and preparing payloads for API submission.

Frequently Asked Questions about task-template-builder

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

FAQPage Schema
How do I keep frontend and backend task-template schemas in sync?

To keep frontend and backend task-template schemas in sync, use a shared Zod schema from @eridu/api-types to enforce a single source of truth and eliminate duplicated validation logic across the stack.

How do I persist task template drafts in IndexedDB to prevent data loss?

To persist task template drafts in IndexedDB and prevent data loss during editing, use the idb-keyval library to store draft data locally before submitting the final payload to the API.

How do I add drag-and-drop ordering for task template fields?

To add drag-and-drop ordering for task template fields, use @dnd-kit with stable IDs to reorder fields and templates directly within the UI, ensuring the updated order is captured accurately.

What is the best way to validate task template payloads before API submission?

The best way to validate task template payloads before API submission is to apply advanced validation and payload transformation using the shared Zod schema, ensuring API compatibility and data integrity.

Does this task template builder approach work without external database dependencies?

Yes, this task template builder approach works without external database dependencies by using IndexedDB via idb-keyval for client-side draft persistence, while the shared Zod schema handles validation without a backend connection.