'defaultLocale' type missing in types
Environment
- Operating System: Darwin
- Node Version: v20.6.1
- Nuxt Version: 3.10.1
- CLI Version: 3.10.0
- Nitro Version: 2.8.1
- Package Manager: [email protected]
- Builder: -
- User Config: devtools, modules, defaultLocale
- Runtime Modules: @nuxt/[email protected]
- Build Modules: -
Reproduction
add this to nuxt.config.ts
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
devtools: { enabled: true },
modules: ['@nuxt/content'],
defaultLocale: 'de'
})
Describe the bug
Following the get started with content.nuxt, there are some types missing, e.g. trying to add defaultLocale shows an error (see screenshot)
Additional context
More generally speaking:
The getting started leaves some questions open... e.g. if you are about to get started, it is not really clear what a useContentHead composable is, or what default behaviour in Change default behaviour of Content APIs. means.
It would be nice, if the getting started provides steps which are possible to follow. As is, I'm lost, because it is unclear which of the configuration properties are required/supported to continue and which ones aren't.
Logs
No response
You should define defaultLocale under content options:
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
devtools: { enabled: true },
modules: ['@nuxt/content'],
content: {
defaultLocale: 'de'
}
})