I want to paint some rows of the table, is it possible to do this?
I mean to put a condition for it to be painted:
if(Object.values(totalDatos[j])[i].tipoUser=='verdadero'
html += "<td if(Object.values(totalDatos[j])[i].tipoUser=='verdadero')
{style.background-color=yellow} >" + Object.values(totalDatos[j])[i] + "</td>";
example:
let condicion = true;
var html = "<table border=2 id='examples'>";
html += "<thead>";
html += "<tr><th colspan='3'>Validacion </th></tr>";
html += "<tr>";
html += "<th style='background-color=yellow;'> intento </th>";
html += "<th > Usuario </th>";
html += "<th > Resultado </th></tr> </thead>";
document.getElementById("tablaVariablesSVM").innerHTML = html;
<div id="tablaVariablesSVM"></div>