MCPcopy Create free account
hub / github.com/Vishal-raj-1/Awesome-JavaScript-Projects / getUser

Method getUser

assets/js/github.js:9–21  ·  view source on GitHub ↗
(user)

Source from the content-addressed store, hash-verified

7 }
8
9 async getUser(user) {
10 const profileResponse = await fetch(`https://api.github.com/users/${user}?client_id=${this.client_id}&client_secret=${this.client_secret}`);
11
12 const repoResponse = await fetch(`https://api.github.com/users/${user}/repos?per_page=${this.repos_count}&sort=${this.repos_sort}&client_id=${this.client_id}&client_secret=${this.client_secret}`);
13
14 const profile = await profileResponse.json();
15 const repos = await repoResponse.json();
16 return {
17 profile,
18 repos
19 }
20
21 }
22
23}

Callers 1

github_app.jsFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected