Created
February 6, 2016 16:52
-
-
Save laere/826b5df5d5f7cb7f259f to your computer and use it in GitHub Desktop.
This file contains hidden or 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
// THIS WILL RETURN API JSON DATA BEFORE FIRST RENDER | |
componentDidMount: function() { | |
fetch('http://swapi.co/api/people').then(function(response) { | |
return response.json() | |
}.bind(this)); | |
console.log(this.state.people); | |
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment