> ## Documentation Index
> Fetch the complete documentation index at: https://docs-loja.usecorvex.com.br/llms.txt
> Use this file to discover all available pages before exploring further.

# collection_list

> Field type collection_list — lista de UUIDs de coleções.

# `collection_list`

| | |
| - | - |
| **type** | `collection_list` |
| **Valor salvo** | `string[]` — UUIDs de categorias |

O lojista escolhe várias coleções. O tema recebe ids de categoria, não os objetos.

## Propriedades

O validador exige `id` e `type`. `label` é recomendado. Sem `max`, o editor usa 10.

Resolva cada id com `storefront.categories.get(id)`. `storefront.collections` é o mesmo cliente (`createStorefront` aponta os dois para `createCategoriesApi`), então `collections.get(id)` é o mesmo método.

## Exemplo

```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
{
  "id": "collections",
  "type": "collection_list",
  "label": "Coleções",
  "max": 6
}
```

## Runtime

```jsx theme={"theme":{"light":"github-light","dark":"github-dark"}}
const collections = await Promise.all(
  (settings.collections || []).map((id) => storefront.categories.get(id))
);
```

Ignore entradas `null` quando o id não existir mais.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.