# flagstaff/log-tail

> Every export of flagstaff/log-tail, with its signature and doc comment: logTail, plus 3 types.

Source: https://flagstaff.interlace.tools/docs/api/log-tail

<!-- Generated by scripts/api-reference.ts from the built dist/*.d.ts. Do not edit; run `npx tsx scripts/api-reference.ts`. -->

```ts
import { logTail } from 'flagstaff/log-tail';
```

## Functions

### logTail

A log tail: the whole stream, appended, off a terminal; its last `height` rows on one.

```ts
function logTail({ height }?: LogTailOptions): Component<LogTailState>;
```

| Parameter | Type |
| :-- | :-- |
| `{ height }` (optional) | `LogTailOptions` |

**Returns** `Component<LogTailState>`

## Interfaces

### LogTailOptions

```ts
interface LogTailOptions {
    /** Rows the tail shows on a terminal. Default 5; anything below 1 is 1. */
    height?: number;
}
```

### LogTailState

```ts
interface LogTailState {
    /** Every entry the stream has produced so far, oldest first. */
    lines: readonly LogLine[];
}
```

## Types

### LogLine

One entry of the stream: a line of output, or the start of a step.

```ts
type LogLine = string | {
    step: string;
};
```
