---
url: /api/kiln/functions/onExit.md
---
[Kiln API](../../index.md) / [kiln](../index.md) / onExit

# Function: onExit()

```ts
function onExit<S>(s, value): Condition;
```

Run condition: true on the first frame (in Fixed: step) after `value` was left.

## Type Parameters

| Type Parameter |
| ------ |
| `S` *extends* `string` |

## Parameters

| Parameter | Type |
| ------ | ------ |
| `s` | [`State`](../interfaces/State.md)<`S`> |
| `value` | `S` |

## Returns

[`Condition`](../type-aliases/Condition.md)
