Handlebars reference

Handlebars reference



Handlebars expressions are available to the rendering engine. There are model specific, general and extension expressions available. The handlebars render engine implements the majority of client side handling. Documentation can be found here: http://handlebarsjs.com/

Model Expressions:

EXPRESSIONDESCRIPTION
modelReturns the full handlebars model in the current context
assetReturnst the Asset behind the model
nameReturns the name of the asset
browser_titleReturns the browser title property
urlReturns the URL of the asst in context
render_meWill render the asset in context after stripping out the Head template
has_childrenReturns 'true' if the asset in context has children
childrenReturns an iteration of the children of the asset in context. You can use the #each helper to iterate
statusReturns the status of the asset 'DRAFT' or 'PUBLISHED'
typeReturns the type of the asset in context
subtypeReturns the subtype of the asset in context
type_and_subtypeReturns the type and subtype of the asset in the format TYPE.SUBTYPE
pidReturns the pointerid of the asset
vidReturns the versionid of the asset
create_userReturns the full name of the user that originally created the asset in context
modify_userReturns the full name of the user that last modified the asset in context
property.NAME
prop.NAME
p.NAME
Returns a value of a property where NAME is the JSON name of the property (there are 2 shortcodes prop and p)
NAVIGATIONAll navigation expressions are prefixed with navigation. navi. or n.

Navigation expressions (prefixed with navigation. navi. n.):

Template expressions (prefixed with template.):

EXPRESSIONDESCRIPTION
template.pointerid OR nicenameLoads a subtype from within the Templates component
template_file 'filepath' 'error_message'Loads a template form file

Retrieving assets (gets. g.):

Security (security. sec. s.):

Dates (dates. d.):

Logic helpers: