Report Word template - HTML with placeholders

Hi there,

Another related question to this one would be if it is possible to inject variables in the HTML code that then also after inserting get replaced by the actual content of the data?

What I mean is this:

I store somewhere externally the following HTML snippet, which is stored under the attribute firstWords in the VisitDocumentation entity.

<h2>Dear Pet ${}</h2>

you have won the <b>lottery</b>.

And this snippet I now want to load from the DB and pass it into the template. In the template, there is the placeholder ${VisitDocumentation.firstWords} that injects it into the right place. But what I would like to see is that the end result is rendered as something like this:

Dear Pet Pikachu

you have won the lottery.

What I’m trying to achieve is to externalize parts of the report content, because I need a lot of logic before the actual rendering. But the content at the end of the day still needs to be merged with the data of the report.