File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed
Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change 11< html >
22 < head >
33 < link rel ="stylesheet " type ="text/css " href ="main.css " />
4- < script src ="https://code.jquery.com/jquery-3.6.0.min.js " integrity ="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4= " crossorigin ="anonymous "> </ script >
54 < script defer src ="main.js "> </ script >
65 </ head >
76
Original file line number Diff line number Diff line change @@ -7,11 +7,10 @@ fetch('https://api.github.com/repos/code4community/git-tutorial/git/trees/master
77 . then ( response => response . json ( ) )
88 . then ( data => {
99 const filenames = data . tree . map ( element => element . path )
10+ const body = document . getElementsByTagName ( 'body' ) [ 0 ]
1011
1112 filenames . forEach ( filename => {
12- $ ( 'body' ) . append (
13- "<div class=\"head-container\"><img class=\"head\" src=\"images/" + filename + "\"/></div>"
14- )
13+ body . innerHTML += "<div class=\"head-container\"><img class=\"head\" src=\"images/" + filename + "\"/></div>"
1514 } )
1615
1716 const people = document . getElementsByClassName ( "head-container" ) ;
You can’t perform that action at this time.
0 commit comments