Browse Source

Add loading function for grabbing data

master
Peter Hajas 3 years ago
parent
commit
f4ba31bdda
  1. 13
      script.js

13
script.js

@ -29,3 +29,16 @@ function animate() {
animate(); animate();
async function doLoad() {
let request = new Request('data.json');
fetch(request)
.then(response => {
return response.json()
})
.then(json => {
console.log(json)
})
}
doLoad();

Loading…
Cancel
Save