Use generators in JavaScript to iterate over a paginated API
Many APIs allow you to retrieve a list of entities. However, returning the whole list in a single response could be an heavy task for the servers, and do you even need the whole list? To mitigate this issue, APIs often use pagination. For example, when you list user repositories with GitHub's API…