-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexport.js
37 lines (31 loc) · 876 Bytes
/
export.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
const hello = `hello at ${Date()}`
let openData={}
openData.cdc = async()=>{
let url = `https://data.ny.gov/resource/5kgr-h5g5.json`
console.log(url)
try{
let d = await (await fetch(url)).json()
return d
} catch (err){
console.log(`${url}`,err)
return undefined
}
}
// ---------------------------------------------------------------------------
openData.socrata = async()=>{
//Detailed Mortality 1999-2013 (D76)
let url = `https://wonder.cdc.gov/controller/datarequest/D76`
console.log(url)
try{
let d = await (await fetch(url)).json()
return d
} catch (err){
console.log(`${url}`,err)
return undefined
}
}
// ---------------------------------------------------------------------------
export { // these are the methods of epiVerseTracker
hello,
openData,
}