Closed
Description
After react native 60 adding custom fonts have changed. Follow this short tutorial to simply add custom fonts in your app.
React Native CLI can be configured by creating a react-native.config.js at the root of the project. Depending on the type of a package, the set of valid properties is different. To add custom fonts we only need to add one line of code: assets: [‘./assets/fonts/’]
Then add your fonts in ./assets/fonts/ directory
And use like this: fontFamily: ‘Roboto-Regular’
Just that simple we have custom fonts in our react native app :)
If you like the article, don’t forget to clap and share it :)
Via Sergo Kupreishvili