# Template Tiger Handlebars Syntax Guide > **Handlebars basics: {{variable}} for values, {{#if}} for conditionals, {{#each}} for loops, {{#with}} for context.** Templates use Handlebars syntax for dynamic content rendering. ## Variable Substitution Basic variable: ```handlebars Hello {{name}}! ``` Nested object access: ```handlebars Hello {{user.firstName}} {{user.lastName}}! Email: {{user.profile.email}} ``` ## Conditionals If/else blocks: ```handlebars {{#if isPremium}} Welcome, premium user! {{else}} Upgrade to premium today. {{/if}} ``` Unless (inverse of if): ```handlebars {{#unless isLoggedIn}} Please log in to continue. {{/unless}} ``` ## Loops Iterating over arrays: ```handlebars
{{@index}}: {{this.name}}
{{/each}} ``` ## Context Switching With block for nested objects: ```handlebars {{#with user}} Name: {{firstName}} {{lastName}} Email: {{profile.email}} {{/with}} ``` ## Complete Example Template: ```handlebarsThank you for being a premium member!
{{else}}Consider upgrading to premium.
{{/if}}