fetch('/schtarr/inno.json')
.then(res => res.json())
.then(json => {
- let out = document.getElementById('clan');
- out.innerHTML = `<h1>${json.tag}</h1><h2 title="Division ${json.division}" class="rank ${json.league}">${json.league} <small>#${json.rank}</small></h2>`
- + json.members.map(member => `<a href="${member.profileUrl}"><figure><img src="${member.avatarUrl}" title="${member.name}" /><figcaption>${member.name}</figcaption></figure></a>`).join('');
+ document.getElementById('clan').innerHTML = `
+ <h1>${json.tag}</h1>
+ <h2 title="Division ${json.division}" class="rank ${json.league}">
+ ${json.league} <small>#${json.rank}</small>
+ </h2>
+ ${json.members.map(member => `
+ <a href="${member.profileUrl}"><figure>
+ <img src="${member.avatarUrl}" title="${member.name}" />
+ <figcaption>${member.name}</figcaption>
+ </figure></a>
+ `).join('')}
+ `
})
.catch(error => console.log(error))
</script>