Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: update to match v2.3 behaviour #1755

Merged
merged 2 commits into from
Dec 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
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