HTML Code Field

HTML Code Field

The htmlcode field stores controlled advanced markup.

Best For

  • advanced custom markup under technical ownership
  • tightly controlled embed fragments
  • cases where structured fields are not sufficient

Schema Example

{ "name": "customMarkup", "label": "Custom Markup", "type": "htmlcode" }

Template Usage

{{{ customMarkup }}}

Controlled embed example:

<div class="custom-embed">
  {{{ customMarkup }}}
</div>

Use It When

Use htmlcode only when a controlled advanced HTML fragment is genuinely required.

Do Not Use It When

Do not use htmlcode when:

  • a structured field model would be clearer
  • editors only need formatted content
  • repeatable rows are needed

Prefer text, textarea, richtext, or repeater whenever possible.

Technical Notes

  • keep htmlcode under clear technical ownership
  • use it for controlled advanced fragments, not as a shortcut around content modeling
  • review rendering impact carefully because markup choices can affect layout, styling, and client behavior
  • if editors mainly need headings, links, lists, or paragraphs, use richtext instead