diff --git a/src/content/docs/en/reference/api-reference.mdx b/src/content/docs/en/reference/api-reference.mdx index ae1201fb929903..96b578a0f9e419 100644 --- a/src/content/docs/en/reference/api-reference.mdx +++ b/src/content/docs/en/reference/api-reference.mdx @@ -1149,6 +1149,8 @@ Content collections offer APIs to configure and query your Markdown or MDX docum ### `defineCollection()` +**Type:** `(input: CollectionConfig) => CollectionConfig` + `defineCollection()` is a utility to configure a collection in a `src/content/config.*` file. ```ts @@ -1187,7 +1189,7 @@ This means collections **cannot** store a mix of content and data formats. You m #### `schema` -**Type:** `TSchema extends ZodType` +**Type:** `TSchema extends ZodType | (context: SchemaContext) => TSchema extends ZodType` `schema` is an optional Zod object to configure the type and shape of document frontmatter for a collection. Each value must use [a Zod validator](https://github.com/colinhacks/zod). @@ -1195,6 +1197,8 @@ This means collections **cannot** store a mix of content and data formats. You m ### `reference()` +