Form templates

Each Section and Repeating section is rendered using a legacy Handlebars template.

Templates can use the built-in templates, or use one of your plugin’s templates. Any template which does not begin "oforms:" will be loaded from your plugin’s template directory.

When using your own template, always specify the template and templateDisplay properties to define the template pair. The templateDisplay could use a default template, for example, "oforms:default:display".

Writing your own template

It’s easy to write custom templates. Write the required HTML as you would any other template, but where you want a form element to appear, use the oforms:element helper like this:

    {{oforms:element "name"}}

This template will work for rendering a form and a document.

Built-in templates

The built-in templates come in pairs, each with a display version named with the ":display" suffix. All the names use the "oforms:" prefix.

oforms:default
oforms:grid
oforms:grid:row
oforms:join
oforms:table