---
title: Folder meta
description: Configure a sidebar group with a meta.ts file beside its pages — set the group's title, icon, order, and the order of the pages nested inside.
---

Every folder in your content tree becomes a sidebar group. Drop a `meta.ts` beside its pages to control how that group looks and how its children are ordered. It's entirely optional: without one, the group's label is the humanized folder name and its pages sort by [index, numeric prefix, then alphabetically](/docs/content/navigation#ordering).

## Defining meta

Export a `defineMeta` object for a fully typed config. Place the file at the root of the folder it configures — `guides/meta.ts` configures the **Guides** group:

```ts meta.ts lineNumbers
import { defineMeta } from "blume";

export default defineMeta({
  title: "Guides",
  icon: "book-open",
  order: 2,
  collapsed: false,
  pages: ["configuration", "theming", "deployment"],
});
```

Every field is optional — set only what you want to override.

## Fields

| Field | Type | Description |
| --- | --- | --- |
| `title` | `string` | The group's label. Defaults to the humanized folder name. |
| `icon` | `string` | Icon shown next to the label. |
| `order` | `number` | Position among sibling groups and pages. Lower numbers sort first. |
| `collapsed` | `boolean` | Under the [`group` display mode](/docs/content/navigation#display-modes), whether the group starts collapsed. |
| `display` | `"flat" \| "group" \| "page"` | Render mode for this group; overrides the global [`navigation.sidebar.display`](/docs/content/navigation#display-modes). |
| `pages` | `string[]` | Explicit order for the group's children, by slug. |

The `pages` array lists children by slug — the folder or file name with its numeric prefix and any parentheses stripped (so `01-quickstart.mdx` is `"quickstart"`). Children you leave out still appear, after the listed ones.

How groups render — flat headers, collapsible disclosures, or drill-in panels — defaults to the sidebar-wide `navigation.sidebar.display`; set `display` here to override it for this group alone. A folder's `index` page can also set it from frontmatter, which wins over `meta.ts` — see [per-group overrides](/docs/content/navigation#per-group-overrides).

## Computed meta

Because `meta.ts` is a real module, you can compute the meta — pass a function (sync or `async`) instead of an object to build it at scan time. Handy for ordering pages from an external source:

```ts meta.ts
import { defineMeta } from "blume";

export default defineMeta(async () => ({
  title: "Guides",
  pages: await orderFromCms(),
}));
```

## Ordering within a group

The `pages` array sets the order of a group's children. Anything it omits falls back to each page's frontmatter `sidebar.order`, then the file system (an `index` page first, then numeric prefixes, then alphabetical). For the full sidebar precedence — including an explicit config sidebar — see [Navigation › Ordering](/docs/content/navigation#ordering).

To group pages _without_ adding a URL segment, you don't need a `meta.ts` at all: use a parenthesized folder name — see [Pages › Group folders](/docs/content#group-folders).

## Internationalization

Under [i18n](/docs/content/i18n), folder meta resolves per locale: put a `meta.ts` under `fr/guides/` to order the French group independently.

For folder meta that's identical in every language, add a `$` marker so one file serves all locales without duplication:

```txt
docs/guides/meta.$.ts   (folder meta applied to every locale)
```

A locale-specific `meta.ts` still overrides the shared `meta.$.ts` for that language.

## Where to next

<CardGroup cols={2}>
  <Card title="Navigation" href="/docs/content/navigation" icon="menu">
    How the sidebar, breadcrumbs, and tabs are built.
  </Card>
  <Card title="Frontmatter" href="/docs/reference/frontmatter" icon="file">
    Per-page metadata, including the `sidebar` overrides.
  </Card>
</CardGroup>
