AngularJS - custom directive with attributes in templateUrl
<p>I have some templates for format text, <em>frecuencia-dia.html</em> or <em>frecuencia-mes.html</em> for example. </p>

<p>I want call a dinamic template using the attributes <em>tipo</em> (text plain) and <em>clave</em> (variable scope).</p>

<pre><code>&lt;ng-formato-texto tipo="frecuencia" clave="{{prod.claveFrecuencia}}" /&gt;

app.directive('ngFormatoTexto', function() {
    return {
        templateUrl: function(elem, attr){
            return '/formats/'+attr.tipo+'-'+attr.clave+'.html';
        }
    };
});
</code></pre>

<p>But don't work, this try load <em>frecuencia-%7B%7Bprod.clavePrueba%7D%7D.html</em></p>