I just upgraded my app to use SDK22 and ran into a really strange error. After the update, my app wouldn’t start (in the iOS simulator). All I got was a white screen and the Exponent app would peg the CPU. If I debugged with the chrome debugger, the app would start and function correctly. However, you could tell there was some background thread pegging the CPU.
After a day of eliminating all the causes I traced it down to 1 line of code I had that looked something like
render() {
return <RootStackNavigator ref={(r) => console.log("got ref", r)}/>;
}
I am using react-navigation and had some logging left from before. If I take out the console.log everything works fine! It looks like some kind of race condition to me. You can reproduce it by taking the default tab navigation expo project and adding the ref property to the RootStackNavigator just as above.