MCPcopy Create free account
hub / github.com/Vishal-raj-1/Awesome-JavaScript-Projects / render

Function render

assets/js/timeline.js:19–49  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

17];
18
19function render (){
20 //
21 var mainBox=document.createElement('div');
22 mainBox.id="mainBox"
23
24 list.map(val=>{
25 var title=document.createElement('h3');
26 var titleText = document.createTextNode(val.title);
27 title.appendChild(titleText);
28
29 var description=document.createElement('h4');
30 var descriptionText = document.createTextNode(val.description);
31 description.appendChild(descriptionText);
32
33 var date=document.createElement('h6');
34 var dateText = document.createTextNode(val.date);
35 date.appendChild(dateText);
36
37 var box=document.createElement('div');
38 box.className="content"
39 box.appendChild(title);
40 box.appendChild(description)
41 box.appendChild(date)
42
43 console.log(box)
44 mainBox.appendChild(box);
45 })
46 var main=document.getElementById("main")
47
48 main.appendChild(mainBox);
49}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected