# types/registry.types.ts

> 8 lines of code and 2 definitions.

Tree: Site tree
Language: typescript
Layer: infrastructure
Canonical: https://banes-lab.com/anatomy/tree#file-types-registry-types-ts
Source text: https://banes-lab.com/assets/sources/source.9a24f2291ce880e7423654092acadb5f76e56e066814b847c7a45cec8f550841.generated.txt

## Definitions

- `Identified` (interface_declaration, line 1, exported)
- `Registry` (interface_declaration, line 5, exported)

## Source

```typescript
export interface Identified {
    readonly id: string;
}

export interface Registry<T extends Identified> {
    readonly all: () => readonly T[];
    readonly byId: (id: string) => T | undefined;
    readonly register: (entry: T) => void;
}
```
