Fall back if error loading fonts

This commit is contained in:
Eric Bailey
2024-09-18 20:08:53 -05:00
parent 2b7abc3541
commit ce5b4ded57
+2 -2
View File
@@ -144,13 +144,13 @@ function InnerApp() {
function App() {
const [isReady, setReady] = useState(false)
const [loaded] = useFonts()
const [loaded, error] = useFonts()
React.useEffect(() => {
initPersistedState().then(() => setReady(true))
}, [])
if (!isReady || !loaded) {
if (!isReady || (!loaded && !error)) {
return null
}