<!-- Generated by scripts/gen-docs.mts from the JSDoc in registry/. Do not edit; run `pnpm run docs`. -->

# markPicturesReady

Marks pictures the app has already loaded and decoded as ready, so an `Avatar` with the same `src` draws the picture on its first frame instead of its initials. An image that is not loaded, or failed, is skipped. Give it images whose `src` attribute is the exact string you pass `Avatar` as `src`.

```tsx
import { markPicturesReady } from "@/lib/ouro/avatar-pictures";
```

## Example

```tsx
const image = new Image();
image.src = "/people/ana.jpg";
await image.decode();
markPicturesReady([image]);
// <Avatar name="Ana Lind" src="/people/ana.jpg" /> now draws the picture on its first frame.
```

## Usage

Use it after warming pictures ahead of time, such as in a list's preload. Without it, an avatar whose picture the browser holds may still draw its initials first.

## Parameters

| Parameter | Type |
| --- | --- |
| `images` | `Iterable<HTMLImageElement>` |

## Returns

`void`
