Created
December 13, 2016 22:50
-
-
Save garlicnation/82b2ecd5380af359923715c81dbe8b07 to your computer and use it in GitHub Desktop.
Async await github api example
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
let tagResponse = await api.gitdata.getTags({owner: org, repo: component}); | |
let allTags = tagResponse.slice(); | |
while (api.hasNextPage(tagResponse)) { | |
tagResponse = await api.getNextPage(tagResponse); | |
allTags = allTags.concat(tagResponse); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment