This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| async function getData(url) { | |
| return new Promise((resolve, reject) => { | |
| https.get(url, (res) => { | |
| let data = ''; | |
| res.on('data', (chunk ) => { | |
| data+= chunk; | |
| }) | |
| res.on('end', () => { | |
| data = JSON.parse(data); | |
| resolve(data); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function sum (a) { | |
| return function (b) { | |
| if (b) { | |
| return sum(a + b); | |
| } else { | |
| return a; | |
| } | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| rm ~/Library/Preferences/com.bjango.istatmenus.plist |
OlderNewer