Created
November 13, 2019 12:09
-
-
Save myogeshchavan97/16ec90d546983d3e537b744a69d8156b to your computer and use it in GitHub Desktop.
Console grouping
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
axios.get('https://randomuser.me/api/?page=1&results=5') | |
.then(response => { | |
const users = response.data; | |
users.results.forEach(user => { | |
const name = user.name; | |
const location = user.location; | |
const email = user.email; | |
console.groupCollapsed('User Details'); | |
console.log(name); | |
console.log(location); | |
console.log(email); | |
console.groupEnd('User Details'); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment