Skip to content

OKD: First steps to use view templates

Instead of mixing the code computing the data and displaying it, introduce a templating system to generate the views (aspiring to become MVC one day).

Each part of the website view will have a dedicated file in templates directory. A created object of the class TemplateWrapper will read the html template from the file and replace the passed parameters (marked in the template with !!NAME!!).

This is a very simple templating system but in the future, we can switch to using a library. :) But for now, the first goal is to replace all the view-generating code with the templates.

Tagging @tamartin

Merge request reports