I have an AngularJS template, which looks like this:
<script type="text/ng-template" id="my_template">
{{ name }}
{{ age }}
</script>
and an object that looks like this:
{
name: "Bob",
age: 31
}
Is there a way I can make Angular return HTML after compiling the template and the data object? Please note that the data object in not inside my scope, it's generated randomly and doesn't exist (nor will exist) in the scope in any moment.
I just want to generate an HTML from the template and the data.
Also, note that I'm not willing to $watch the data object for any changes.