Skip to content

Commit

Permalink
hackathon w/ carol
Browse files Browse the repository at this point in the history
  • Loading branch information
dennishly committed Jun 16, 2022
1 parent 6de5b1c commit 8c1d9d3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 47 deletions.
34 changes: 0 additions & 34 deletions index.html

This file was deleted.

8 changes: 4 additions & 4 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"name": "Covid-19 Stats UK",
"name": "Pokedex",
"version": "1.0.0",
"description": "latest covid data of UK",
"description": "get first gen pokemon data",
"manifest_version": 3,
"author": "Sampurna Chapagain",
"author": "Dennis Ly and Carol Xia",
"action":{
"default_popup": "index.html",
"default_title": "Latest Covid Report"
"default_title": "Pokedex"
}
}
22 changes: 13 additions & 9 deletions script.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
async function fetchData() {
const res = await fetch ("https://api.coronavirus.data.gov.uk/v1/data");
const record = await res.json();
console.log(record);
document.getElementById("date").innerHTML=record.data[0].date;
document.getElementById("areaName").innerHTML=record.data[0].areaName;
document.getElementById("latestBy").innerHTML=record.data[0].latestBy;
document.getElementById("deathNew").innerHTML=record.data[0].deathNew;
// async function fetchData() {
// const res = await fetch ("https://api.coronavirus.data.gov.uk/v1/data");
// const record = await res.json();
// console.log(record);
// document.getElementById("date").innerHTML=record.data[0].date;
// document.getElementById("areaName").innerHTML=record.data[0].areaName;
// document.getElementById("latestBy").innerHTML=record.data[0].latestBy;
// document.getElementById("deathNew").innerHTML=record.data[0].deathNew;
// }
// fetchData();

function togglePokemonList(){
document.getElementById("pokemon-types").classList.toggle("show");
}
fetchData();

0 comments on commit 8c1d9d3

Please sign in to comment.