examples
github stars
bitty's repo has some stars.
feel free to add more.
- The example starts with a basic text saying the repo has "some" starts.
- A call is made to the GitHub API to pull the actual number.
- If the call succeeds the value is updated. Otherwise, nothing changes.
- Aside: This approach is basic and results in a visual change when the data loads for the demonstration. I'd hide the entire string until the data loaded in real world usage.
html
bitty's repo has some stars.
feel free to add more. javascript
;
const url = "https://api.github.com/repos/alanwsmith/bitty";