# Function: typed()

```ts
function typed<T>(): <C>(definition) => C & Typed<T>;
```

Defined in: [packages/core/src/schemas/fragments.ts:18](https://github.com/leifriksheim/minca/blob/main/core/src/schemas/fragments.ts#L18)

A definition that also carries its records' type, so querying or writing
with it is typed — `include: { votes: { rel: 'about', from: vote } }` gives
votes as `Vote`. The schemas here are plain JSON Schema, so the type is said
alongside rather than worked out.

## Type Parameters

| Type Parameter |
| ------ |
| <a id="type-parameter-t"></a> `T` |

## Returns

\<`C`\>(`definition`) => `C` & [`Typed`](https://minca.dev/api/core/interfaces/Typed.md)\<`T`\>
