Templates Overview & Quick Reference

Welcome to the Aurelia templating documentation! This guide covers everything you need to build dynamic, interactive UIs with Aurelia's powerful templating system.

Quick Start

New to Aurelia templates? Start here:

  1. Cheat Sheet - Quick syntax reference for all template features

  2. Template Syntax Overview - Core concepts and features

  3. Real-World Recipes - Complete working examples

How Do I...?

Find what you need quickly with this task-based guide:

Display Data

Work with Lists

Handle User Input

Conditional Logic

Styling

Components

Forms

Advanced

Documentation Structure

Core Concepts

Template Syntax

Display Logic

Data Transformation

Forms & Input

Extensibility

Other Features

Real-World Examples

  • Recipes - Complete, production-ready examples

    • Product Catalog - Search, filter, sort

    • Shopping Cart - Add/remove items, calculate totals

    • More coming soon—follow the contribution guide in the recipes index to share yours!

Learning Path

Not sure where to start? Follow this path:

Beginner

  1. Try Event Binding for interactivity

Intermediate

  1. Master Conditional Rendering (if, show, switch)

  2. Learn List Rendering (repeat.for)

  3. Explore Value Converters for data formatting

  4. Build forms with Forms Guide

Advanced

  1. Use Binding Behaviors for fine control

  2. Adapt real-world patterns from the Template Recipes collection

Performance Tips

  • Use .one-way binding for display-only data

  • Add key to repeat.for for dynamic lists

  • Use show.bind for frequent visibility toggles

  • Use if.bind for infrequent changes

  • Debounce rapid input events

  • Keep expressions simple - move logic to view model

Common Pitfalls

  • Components not appearing? → Don't forget <import from="./component"></import> (or register globally)

  • Array changes not detected? → Use array methods like push(), splice(), not direct index assignment

  • Form input not updating? → Use .bind or .two-way, not .one-way

  • Performance issues with large lists? → Add key.bind or key: to repeat.for

  • Bindings not working? → Check for typos in property names and binding commands

Need Help?

Last updated

Was this helpful?