Quantcast
Channel: React Native importing fonts with async componentDidMount() expected => - Stack Overflow
Browsing all 2 articles
Browse latest View live

Answer by Oleg for React Native importing fonts with async...

If you want to use Functional Component with hooks, try like this: add to imports: import { useState, useEffect } from 'react'; and const Home = () => { const [fontLoaded, setFontLoaded] =...

View Article



React Native importing fonts with async componentDidMount() expected =>

I am trying to import a font for a title of a project, and I am loading the font as such: import * as Font from 'expo-font' const Home = () => { return( this.state = { fontLoaded: false } async...

View Article
Browsing all 2 articles
Browse latest View live




Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>
<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596344.js" async> </script>