Using Placeholders in Templates
Jedison allows you to define templates with dynamic titles and descriptions that use placeholders. These placeholders are replaced at runtime with relevant values.
Available Placeholders
value— The current value (fromgetValue()); always availablesettings— Configuration options (fromjedison.options.settings); always availablei0— The zero-based index of the array item; available only if the editor is an array item editori1— The one-based index of the array item; available only if the editor is an array item editorparent— Parent instance template data; available when parent existslength— The length of the string value; available only for string typesremaining— Characters remaining (maxLength - length); available only for strings with maxLength
Fallback Values
Use the || operator inside a placeholder to provide a fallback value when the placeholder resolves to null or undefined:
{{ value.name || 'Unnamed' }}The fallback can be any quoted string (single or double quotes). When the placeholder has a value, the fallback is ignored.
Parent Template Access
When working with nested structures, you can access parent instance data using the parent placeholder. This is particularly useful for creating hierarchical titles and references.
Common Parent Access Patterns
parent.value— Access the parent's current valueparent.i1— Access the parent's array index (1-based)parent.parent.value— Access grandparent's value (for deeply nested structures)