Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var axios = require ('axios');
- var URL = "https://swapi.co/api";
- try{
- axios.get(URL+'/people/1')
- .then(function(response) {
- console.log(response.data);
- })
- }
- catch (err) { alert(err);};
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement