IS
Size: a a a
IS
IS
ВЛ
IS
55
<div class="table-wrapper">
<table class="fl-table">
<thead>
<tr id="tableName">
</tr>
</thead>
<tbody id="data">
<tbody>
</table>
</div>
Jsconst nameColumn = document.getElementById('tableName');
const dataColumn = document.getElementById('data');
const serverRequest = () => {
fetch('http://127.0.0.1:5000')
.then((resp) => resp.json())
.then((data) => {
console.log(Object.keys(data[0]))
for (let i = 0; i <= Object.keys(data[0]).length - 1; i++) {
// console.log(Object.keys(data[0]).length)
nameColumn.innerHTML += `<th>${Object.keys(data[0])[i]}</th>`
}
data.map((item) => {
console.log(item)
})
})
};
serverRequest();
55
IS
IS
55
IS
55
IS
55
IS
55
55
IS
55
IS
55