Skip to content

Commit

Permalink
Update src/githubApiIntegration.js
Browse files Browse the repository at this point in the history
  • Loading branch information
gitauto-ai[bot] authored Nov 27, 2024
1 parent 74b3f97 commit 6337c0e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/githubApiIntegration.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Function to fetch data from GitHub API
async function fetchGitHubData(endpoint) {
const response = await fetch(`https://api.github.com/repos/your-repo/${endpoint}`);
if (!response.ok) {
throw new Error('Network response was not ok');
}
return await response.json();
}

export { fetchGitHubData };

0 comments on commit 6337c0e

Please sign in to comment.