Skip to content

Instantly share code, notes, and snippets.

@Madmals
Last active September 13, 2021 18:04
Show Gist options
  • Save Madmals/7ed8b7aadfc107f808bb659c92f22e78 to your computer and use it in GitHub Desktop.
Save Madmals/7ed8b7aadfc107f808bb659c92f22e78 to your computer and use it in GitHub Desktop.
GET METHOD FETCH GIST
// access token in setting then developer
const token = access_token
const githubgist = async ()=>{
let res = await fetch('https://api.github.com/gists',{
'headers': {'Authorization': `token ${token}`}
})
let data = await (res.json())
console.log(data)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment