Skip to content
  1. Extras
  2. PageBuilder
  3. Field types
  4. Pro
  5. chunk

Field chunk

Version: Pro.

Why this type

Chunk picker by name without typing. {include file="file:chunks/{$chunk.name}.tpl"} pattern. Pro for dynamic partial sections.

When to use

  • Editor picks variant chunk layout
  • A/B partial swap in custom section
  • Dev-curated allowed chunk list

Tips

Snippet call is snippet type. Static chunk name can be text if list is closed.

Similar types

  • snippet for modSnippet name
  • combo optionsSource modChunk for id-style pick

Schema

json
{
  "name": "chunk",
  "type": "chunk",
  "label": "Chunk",
  "tab": "Content",
  "width": 100,
  "active": true
}

Value

Object { name }.

Section data

Key chunk in the section data:

json
{
  "chunk": {
    "name": "pbHero"
  }
}

Chunk example

fenom
{include file="file:chunks/{$chunk.name}.tpl"}

Common properties

For fields with name that are stored in the section data:

KeyTypeRoleCMP
tabstringGroup subtitle in the inspectoryes
width25–100Field width as % of the row (flex)yes
descriptionstringHint under the labelyes
defaultanyInitial value for a new sectionyes
activeboolfalse hides the field in the inspectoryes
requiredboolRequired on publish (draft still saves)yes

See fields overview.

See also