Reputation: 5627
How can I use a function that returns html within a string, inside a html template in google apps script ?
For example, here is my code.gs:
function doGet() {
return HtmlService.createTemplateFromFile('test').evaluate();
}
function getHtml(){
return "<b> hello there </b>";
}
and in my html file 'test.html' I have the following:
<html>
<?= getHtml() ?>
</html>
You will see the result is something like this:
How can I change this so it produces hello there in bold, without showing the tags ?
Many thanks
Upvotes: 0
Views: 1911