Hackerss.com is a community of amazing hackers

Hackerss is a community for developers, data scientitst, ethical hackers, hardware enthusiasts or any person that want to learn / share their knowledge of any aspect of digital technology.

Create account Log in

Posted on

Javascript Example of a call to an external api

//function to get data from an external api
function getData(url) {
  //return the data from the api
  return "data";

//function to display the data
function displayData(data) {
  //display the data

const data = getData("https://api.github.com/users/joshua-miller");
displayData(data); //data from the api

Enter fullscreen mode Exit fullscreen mode

Top comments (0)