# Error

Extracts the typed error channel of an `EventHandler`.

## Signatures

```ts
export type Error<T> = T extends EventHandler<infer _Ev, infer E, infer _R> ? E : never;
```

## Why

Handler failures remain visible when a handler is embedded in a template.

## Ownership and lifetime

This is a compile-time projection and has no runtime lifetime.

## Examples

```ts
import type { Error, EventHandler } from "@typed/template/EventHandler"

type Failure = Error<EventHandler<MouseEvent, "save-failed">>
```
