TL;DR Let's build a simplistic template engine and explore how it works under the hood – in case you were ever wondering. If you wish to dive straight into the code, then Github is your friend. Language design Our language is pretty basic. We will have two types of tags, variables and blocks. <!-- variables are surrounded by `{{` and `}}` --> <div>{{my_var}}</div> <!-- blocks are surrounded by `{%