forked from adamszaruga/rendering
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrenderStudents.js
More file actions
37 lines (33 loc) · 725 Bytes
/
renderStudents.js
File metadata and controls
37 lines (33 loc) · 725 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
function renderStudents(students) {
return `
<div class="text-center mt-5">
<code>${JSON.stringify(students)}</code>
</div>
`
}
function students() {
var content = document.getElementById('content');
var studentsAbstraction = [
{
name: "Kamilah",
isPresent: true
},
{
name: "Kim",
isPresent: true
},
{
name: "Stuart",
isPresent: false
},
{
name: "Ron",
isPresent: true
},
{
name: "Krissy",
isPresent: false
}
]
content.innerHTML = renderStudents(studentsAbstraction);
}