mds-datastar-patterns

Standardize Datastar attributes, signals, events, and SSE patterns in repositories.

Updated Jan 6, 2026
One-click install
npx skills add https://github.com/eboody/eran.codes --skill mds-datastar-patterns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mds-datastar-patterns
Source: https://github.com/eboody/eran.codes/tree/main/.codex/skills/mds-datastar-patterns
Command: npx skills add https://github.com/eboody/eran.codes --skill mds-datastar-patterns

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides standardized patterns for using Datastar attributes, signals, events, and Server-Sent Events (SSE) within the repository, ensuring consistency and maintainability in UI and application development.

Core Features & Use Cases

  • Pattern Enforcement: Guides the application of Datastar concepts to ensure adherence to project standards.
  • Scope Classification: Helps determine the appropriate interaction scope (ui_local, command_sse) for different types of UI and application events.
  • State Authority Management: Clearly defines which parts of the state are managed by the UI and which must be updated via the application backend through SSE.
  • Use Case: When designing a new feature involving dynamic data updates on a dashboard, consult this Skill to correctly implement SSE for backend-driven state changes and local expressions for UI-specific state.

Quick Start

Apply the Datastar signal and SSE patterns before defining UI bindings and event handlers.

Frequently Asked Questions about mds-datastar-patterns

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

FAQPage Schema
How do I manage state authority splits between UI signals and backend SSE in Datastar?

State authority splits in Datastar are managed by classifying interaction scopes, keeping UI-specific state in local signals and updating backend-driven state through Server-Sent Events (SSE). This separation enforces consistency and maintainability across application architecture.

What is the best way to structure Datastar events and SSE for dynamic dashboard updates?

Structuring Datastar events for dashboards involves applying SSE convergence patterns for backend-driven state changes and local expressions for UI-specific state. You must define interaction scopes like `ui_local` or `command_sse` before defining UI bindings and event handlers.

When do I need Server-Sent Events (SSE) versus local UI bindings in a Datastar application?

You need Server-Sent Events (SSE) when backend-driven state changes must converge on the client, while local UI bindings handle UI-specific state. Determining the appropriate interaction scope (`ui_local`, `command_sse`) standardizes event handling and enforces state authority boundaries.

How do I enforce consistent Datastar signal patterns across a repository?

Enforcing consistent Datastar signal patterns across a repository requires adhering to defined architectural baselines for attributes, signals, events, and SSE. This standardization guides decisions on UI bindings and routes edge cases through documentation librarians.

Does Datastar support routing edge cases in application architecture through documentation?

Datastar supports routing edge cases through documentation librarians to enforce defined architectural baselines. This ensures that deviations in UI bindings, event handlers, and SSE convergence are standardized and properly documented within the repository.