Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions docs/content/4.api/3.configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,21 @@ export default defineNuxtConfig({
})
```

## `base`
## `api`

- Type: `String`{lang=ts}
- Default: `'/_content'`{lang=ts}
- Type: `Record<String, any>`{lang=ts}
- Default: `{ baseURL: '/api/_content' }`{lang=ts}

Change default behaviour of Content APIs.

Base route that will be used for content api.
- `baseURL`{lang=ts}: change the base URL of Content APIs. Default is `/api/_content`.

```ts [nuxt.config.ts]
export default defineNuxtConfig({
content: {
base: '/_content'
api: {
baseURL: '/api/_my_content'
}
}
})
```
Expand Down Expand Up @@ -313,6 +317,10 @@ List of locale codes. This codes will be used to detect contents locale.

Default locale for top level contents. Module will use first locale code from `locales` array if this option is not defined.

::alert
Note that in case of defining multiple locales, Module will filter content with `defaultLocale`. If you want to fetch contents of another locale, you need to use `where` option.
::

## `documentDriven`

- Type: `Boolean | Object`{lang=ts}
Expand Down