---
url: >-
  https://lit-ui-router.dev/api/ui-router-server/fetch/type-aliases/DelegateKey.md
---
[ui-router-server](../../index.md) / [fetch](../index.md) / DelegateKey

# Type Alias: DelegateKey\<Decls>

```ts
type DelegateKey<Decls> = string extends Decls["name"] ? string : Decls extends {
  delegate: infer K;
} ? K : never;
```

Defined in: [fetch.ts:87](https://github.com/simshanith/lit-ui-router/blob/3ab90929a8d23dda96e259d7396a274c5b05398e/packages/ui-router-server/src/fetch.ts#L87)

The delegate keys a router's states name: `string` for an untyped router.

## Type Parameters

| Type Parameter | Default type |
| ------ | ------ |
|  `Decls` *extends* [`RouteDeclaration`](../../redirects/interfaces/RouteDeclaration.md) | [`RouteDeclaration`](../../redirects/interfaces/RouteDeclaration.md) |
