The configuration cascade is a set of sources containing customizable options for the editor. Each source has a different scope and priority. This allows you to set global defaults and override those for specific collections or files.
When CloudCannon needs an option you have set in the configuration cascade, it looks at each scope in order. In most cases, the cascade stops looking when an option is found. This means the most specific value is used in place of any less specific values.
Input configuration (i.e. _inputs
) has a different cascading default, where CloudCannon continues looking over less specific sources to merge into a single option.
Sources#
The configuration cascade sources are as follows, from lowest priority to highest:
- CloudCannon configuration file
- Collection configuration
- Schema configuration
- Front matter
- Containing structure
Global configuration#
For configuring everywhere on your site. For example:
Collection configuration#
For configuring all files within a collection. For example:
Schema configuration#
For configuring all files within one of a collection's schemas. For example:
Front matter#
For configuring a single file. For example:
Containing structure#
For configuring inputs inside a structure. For example:
For nested structured data, you can nest _structures
alongside the other configuration groups inside a structure definition.
Options#
Since configuration cascade options can be defined alongside your data, they always begin with an underscore in an effort to avoid clashing with a key you would use.
The following configuration cascade options are available:
Contains options for the WYSIWYG toolbar in the Content Editor and rich text inputs. Read more about the configuring your rich text toolbar options.
Controls how your team edits specific files, use this to set a preferred editor and/or disable the others. The first value sets which editor opens from the collection list, the other values specify which editors are accessible. Available values are:
visual
for the Visual Editorcontent
for the Content Editordata
for the Data Editor
The Source Editor is always available for those with permission.
Contains configuration for controlling the behavior and appearance of your inputs in the Data Editor. Read more about how inputs work.
This key defines which data is available to populate Select and Multiselect inputs at a given level of the configuration cascade.
This key has no default. If undefined at higher levels of the configuration cascade, _select_data
will default to any values configured in the CloudCannon configuration file.
For more information, please read our documentation on Select and Multiselect inputs.
Provides structure definitions at a global scope. This allows you to provide multiple values when editors set objects or add items to arrays in the Data Editor.