andstor / jekyll-theme-paper

:book: Paper is a Jekyll theme for project documentation
https://andstor.github.io/jekyll-theme-paper/
MIT License
9 stars 1 forks source link

Cache API fetch results and only make conditional requests #1

Open andstor opened 5 years ago

andstor commented 5 years ago

GitHub API v3 has a rate limit of 60 requests per hour.

To stay within this limit, requests should be made conditional. See conditional requests.

This could be implemented by caching the results, and only re-fetch if TTL (time to live) is expired. Also, then check if the ETag is different.

andstor commented 4 years ago

Fix this by using active-cache.