hwc-realtime-streaming
Installation
SKILL.md
Real-Time & Streaming
Implement push-driven Hotwire behavior with Turbo Streams and Stimulus.
Core Workflow
- Identify transport and delivery shape: WebSocket, SSE, inline stream tags, or server response streams.
- Choose default Turbo Stream actions first; add custom actions only when defaults are insufficient.
- Keep stream actions small and deterministic; avoid embedding arbitrary scripts in stream payloads.
- Separate stream orchestration from domain UI concerns (forms, media, navigation).
- Verify ordering, idempotency, and multi-tab behavior for all real-time updates.
Guardrails
- Prefer
append/prepend/replace/update/remove/before/after/refreshbefore custom actions. - Keep cross-tab sync explicit (BroadcastChannel/localStorage) and scope it to same-device semantics.
- Use view transitions only where animation meaningfully improves state-change clarity.
- Validate failure modes for delayed/out-of-order messages.
Related skills