Skip to content
Strife Docs

Reference

Fields

Fields define the structure and content of your templates. Each field specifies the shape and characteristics of the data that will be stored in the database.

Warning:

This documentation page is still in progress and may not be fully complete. Please check back later for updates.

Basic Field Settings

All fields come with a standard set of basic settings:

OptionDescription
Name*
This setting is mandatory. It determines the property name used for storing and retrieving data from the database. It should be a unique identifier for each field and in camel case.
Label*
This is the text used as a field label when you're editing the field inside Strife. It provides a human-readable name for the field.
Tooltip
This setting allows you to provide additional information or hints about the field. Tooltips are displayed when users hover over or focus on the field.
Autofocus
Autofocus can be enabled to make the field automatically selected or focused when editing, streamlining the user experience.
Validation text
You can define custom validation text here to provide guidance or error messages when users input data that doesn't meet specific criteria.
Tab Group
Groups fields under a specific tab in the editor
Localizable
Enabling this settings allows the field to be localizable
Tab group
When your template includes a Tab Group, use this setting to determine which tab the field should appear under in the editor. See this page for more info.

Each field, depending on its type, may offer additional settings to further customize its behavior. For specifics on these additional settings, please refer to the documentation for each respective field.

JSON Definition

When templates are defined using JSON, the basic field settings form the foundation of each field's configuration within the editors array. These settings control how fields behave and appear inside Strife Studio. For additional information on defining templates with JSON, refer to this page.

Each field in the editors array follows this structure:

JSON
{
  "label": "...",              // Label
  "description": "...",        // Tooltip
  "editor": {
    "name": "...",             // Field component name*
    "type": "...",             // Field component type*
    "propertyName": "...",     // Name
    "attributes": {
      "autofocus": true,       // Autofocus
      "validationText": "...", // Validation text
      "tabGroup": "...",       // Tab Group
      ...
    }
  },
  "localizable": true          // Localizable
}
Note:

*Refer to each field’s documentation for component name, type and additional attributes.

Live Preview Integration for Fields

Fields will automatically transmit their current state to the live preview while a user is editing a field. To enable live preview integration, the website's markup must be upgraded to incorporate Strife view components. You can find detailed instructions on how to set up the live preview here. Please refer to the documentation for each respective field to learn about the view components compatible with that specific field.