Skip to content

Instantly share code, notes, and snippets.

@rootasjey
Last active November 23, 2018 21:58
Show Gist options
  • Save rootasjey/81447690613d71f193d954b660754b98 to your computer and use it in GitHub Desktop.
Save rootasjey/81447690613d71f193d954b660754b98 to your computer and use it in GitHub Desktop.
Fitbit fetch example
// Companion
fetch(encodeURI(url))
.then(response => response.json())
.then(data => {
// Post-processing
// ...
resolve(data)
})
.catch(e => reject(e.message))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment