---
title: "PrerenderPaths"
description: "A function that decides which paths to prerender, for path sets that need async work — a CMS query, a filesystem scan, a database read."
url: "https://pitlane.tools/package/vite-plugin-remix/type/PrerenderPaths"
---

# PrerenderPaths

```ts
import type { PrerenderPaths } from "@pitlane/vite-plugin-remix";
```

```ts
type PrerenderPaths = (context: PrerenderContext) =>
  | string[]
  | Promise<string[]>
  | Iterable<string>
| Promise<Iterable<string>>;
```

A function that decides which paths to prerender, for path sets that need async work — a CMS query, a filesystem scan, a database read.

## Parameters

### context

[`PrerenderContext`](https://pitlane.tools/package/vite-plugin-remix/interface/PrerenderContext.md)

## Returns

| `string`\[\] | `Promise`\<`string`\[\]> | `Iterable`\<`string`> | `Promise`\<`Iterable`\<`string`>>
