In this lesson, you will become familiar with the concept of “templating engines“, which render input data into output document (like HTML) through a template. We will explain how templates combine markup code with programming constructs to visualize data in a target output format.
Â
Along with the slides, at the end of the lesson, we have included a live code example, so you can see how we can render an HTML-based UI with a templating engine. We will use a JSON dataset and the Handlebars templating engine in JavaScript to render the dataset as HTML document.
Â
Templating engines render data as HTML or other format through a template.
This is very useful, when you want to visualize data, which comes from the server-side or from a database.
The template is written in some templating language like Razor, Handlebars or Pug.
Typically, templates combine HTML with special tags.
Templates can render variables, iterate over a collection and perform conditional checks.
You will definitely use templating engines in some form, if you work with data and visualization.
Lesson Topics
In this video we review the following topics:
- Overview of Templating Engines
- Live Demo – Rendering UI with a Templating Engine