I\'m trying to load a splash screen for an iOS app built in React Native. I\'m trying to accomplish this through class states and then a setTimeout function as follows:
Same as above, might help some people.
setTimeout(() => { if (pushToken!=null && deviceId!=null) { console.log("pushToken & OS "); this.setState({ pushToken: pushToken}); this.setState({ deviceId: deviceId }); console.log("pushToken & OS "+pushToken+"\n"+deviceId); } }, 1000);