I'm somewhat new to React / React Native and after updating a project from a previous version of Expo, I keep running into odd "uncaught errors" with what seems to be Expo's Screen Orientation that holds the app back from loading.
Based on Expo's documentation (listed below), I've attempted to rewrite how the app is enforcing a specific screen orientation on load, but I keep running into errors.
ScreenOrientation.lockAsync(ScreenOrientation.Orientation.LANDSCAPE);
if (!this.state.isReady) {
return <Expo.AppLoading />;
}
ScreenOrientation.lockAsync(ScreenOrientation.Orientation.LANDSCAPE_LEFT);
return (
Originally, the application loaded in landscape and locked, but now the app is getting held up on a "invariant violation" error. To view a screenshot of the error that's being produced, please check out the link below.