I'm trying to call a function to change the type of my imput.
<input type="getTypeHtml({{tipoDeDado}})"
function
function getTypeHtml(tipoDeDado) {
var typeHtml = 'text';
switch (tipoDeDado) {
case 0: typeHtml = 'text'; break;
case 1: typeHtml = 'number'; break;
case 2: typeHtml = 'datetime-local'; break;
case 3: typeHtml = 'number'; break;
case 4: typeHtml = 'radio'; break;
default: typeHtml = 'text'; break;
}
return typeHtml;
};
But I can not call using x-handlebars-template interpolation.