My current testing routine involves using Javascript to create a div element, append it to the body, and then set its innerHTML property to:
<p>{{testVar}}</p>
The code I use looks like this:
var created = document.createElement('h1');
var elem = document.body.appendChild(created);
elem.innerHTML='<p>{{testVar}}</p>';
However, when the element is displayed on the page, the double curly brackets are not being interpreted correctly. How can I dynamically add this single element to my page in a way that recognizes the interpolation?