React Native Await Async does not return value before alerting user and setting state – Twitter API
I am using Axios to make HTTPS calls to the twitter API and return tokens and tweets: TwitterScreen.js: export default class TwitterLogin extends React.Component { async componentDidMount(){ await init("<CUSTOMER KEY>", "<CUSTOMER SECRET KEY>"); this.twitter = await getToken(); alert(this.twitter); } render()…