fix(docs-i18n): clarify i18n configuration for file collections (#5028)
This commit is contained in:
parent
36608f8d75
commit
e9462b5c93
@ -98,6 +98,26 @@ collections:
|
||||
i18n: true
|
||||
```
|
||||
|
||||
When using a file collection, you must also enable i18n for each individual file:
|
||||
|
||||
```yaml
|
||||
collections:
|
||||
- name: pages
|
||||
label: Pages
|
||||
# Configure i18n for this collection.
|
||||
i18n:
|
||||
structure: single_file
|
||||
locales: [en, de, fr]
|
||||
files:
|
||||
- name: about
|
||||
label: About Page
|
||||
file: site/content/about.yml
|
||||
# Enable i18n for this file.
|
||||
i18n: true
|
||||
fields:
|
||||
- { label: Title, name: title, widget: string, i18n: true }
|
||||
```
|
||||
|
||||
### Field level configuration
|
||||
|
||||
```yaml
|
||||
|
Loading…
x
Reference in New Issue
Block a user