| 1 | <h2>Comments</h2> |
| 2 | <pre><code>{{! This is a comment with <p>some markup</p> in it }} |
| 3 | {{! This is a comment }} {{ this_is_not }}</code></pre> |
| 4 | |
| 5 | <h2>Variables</h2> |
| 6 | <pre><code><p>{{ text }}</p> |
| 7 | <h1>{{article.title}}</h1> |
| 8 | {{{ triple_stash_is_supported }}} |
| 9 | {{articles.[10].[#comments]}}</code></pre> |
| 10 | |
| 11 | <h2>Strings, numbers and booleans</h2> |
| 12 | <pre><code>{{{link "See more..." story.url}}} |
| 13 | {{ true }} |
| 14 | {{ custom_helper 42 href="somepage.html" false }}</code></pre> |
| 15 | |
| 16 | <h2>Block helpers</h2> |
| 17 | <pre><code><div class="body"> |
| 18 | {{#bold}}{{body}}{{/bold}} |
| 19 | </div> |
| 20 | {{#with story}} |
| 21 | <div class="intro">{{{intro}}}</div> |
| 22 | <div class="body">{{{body}}}</div> |
| 23 | {{/with}} |
| 24 | <div class="{{#if test}}foo{{else}}bar{{/if}}"></div> |
| 25 | {{#list array}} |
| 26 | {{@index}}. {{title}} |
| 27 | {{/list}} |
| 28 | {{#block-with-hyphens args=yep}} |
| 29 | This should probably work... |
| 30 | {{/block-with-hyphens}} |
| 31 | </code></pre> |