docs: realtime now optional — Status headers + conditional HTML rendering

This commit is contained in:
2026-05-09 13:46:41 +02:00
parent 57b2ff5191
commit 39fd2a9f80
3 changed files with 4 additions and 2 deletions

View File

@@ -2192,7 +2192,7 @@ footer .colophon {
<div class="tradeoff-card">
<div class="tag">di/bind-production.ts</div>
<h3>Production binder</h3>
<p class="blurb"><code>bindProduction&lt;F&gt;(ctx: BindProductionContext)</code> — unbinds the mock, rebinds the real Payload-backed impl. The <code>ctx</code> arg carries required fields (<code>tracer</code>, <code>logger</code>, <code>config</code>) and optional cross-cutting deps (<code>bus</code>, <code>queue</code>, <code>realtime</code>, <code>realtimeRegistry</code>).</p>
<p class="blurb"><code>bindProduction&lt;F&gt;(ctx: BindProductionContext)</code> — unbinds the mock, rebinds the real Payload-backed impl. The <code>ctx</code> arg carries required fields (<code>tracer</code>, <code>logger</code>, <code>config</code>) and optional cross-cutting deps (<code>bus</code>, <code>queue</code>). Realtime deps (<code>realtime</code>, <code>realtimeRegistry</code>) are also optional — present only when <code>@repo/core-realtime</code> is scaffolded via <code>pnpm turbo gen core-package realtime</code>.</p>
<div class="pc-cols">
<div class="pros"><h5>Pros</h5><ul>
<li>Decouples Payload config from the feature package — boundary stays clean</li>

View File

@@ -1,6 +1,6 @@
# ADR-016 — Realtime layer (Socket.IO)
**Status:** Accepted
**Status:** Optional — scaffold via `pnpm turbo gen core-package realtime`. The package is not in the default template; this ADR documents the design that the generator emits.
**Date:** 2026-05-08
**Spec:** docs/superpowers/specs/2026-05-08-realtime-design.md
**Plan:** docs/superpowers/plans/2026-05-08-realtime-layer.md

View File

@@ -1,5 +1,7 @@
# Realtime
> **Prerequisite:** This guide assumes `@repo/core-realtime` is present. If you started from the slim template, run `pnpm turbo gen core-package realtime` first.
Walkthrough for adding Socket.IO realtime channels, broadcasts, and inbound handlers to a feature. For the architectural rationale, see [ADR-016](../decisions/adr-016-realtime-layer.md) and [the full spec](../superpowers/specs/2026-05-08-realtime-design.md).
The three rules to keep in mind: