# ssrForHttp

Registers buffered, GET-only HTML routes for a matcher.

Path captures take precedence over same-named query parameters. Rendering
completes before the response is created; this adapter does not stream.

## Signatures

```ts
export declare const ssrForHttp: {
    <E, R>(input: Matcher<RenderEvent, E, R>): (router: HttpRouter) => SsrForHttpEffect<E, R>;
    <E, R>(router: HttpRouter, input: Matcher<RenderEvent, E, R>): SsrForHttpEffect<E, R>;
};
```

## Why

Typed route matchers already describe decoding, guards, parent prefixes, and
render output. `ssrForHttp` installs that same model in Effect's HttpRouter
and buffers one complete HTML document for runtimes that require a known body.

## Ownership and lifetime

Registration adds GET routes to the supplied Effect HttpRouter. Each request
creates request-local memory navigation and current-route services; the
request Effect owns rendering and all finalizers. Buffered rendering must
complete before the response is returned. Rendering HTML does not mount or
hydrate a browser client.

## Routing behavior

Matcher cases sharing a path are tried in their compiled order. Path params
overwrite same-named query params. Decode/guard failures continue candidate
selection; a matched renderer failure stays in the typed request error channel.

## Examples

```ts
import { ssrForHttp } from "@typed/ui/HttpRouter"
import { Effect } from "effect"
import * as HttpRouter from "effect/unstable/http/HttpRouter"
import { Parse, match } from "@typed/router"
import { html } from "@typed/template"

const pages = match(Parse("/"), html`<h1>Home</h1>`)
const routes = Effect.gen(function* () {
  const router = yield* HttpRouter.make
  yield* ssrForHttp(router, pages)
  return router
})
```
