Quantcast
Viewing all articles
Browse latest Browse all 17061

Why I got error message custom font, react native?

I have been desperate for 2 days. I am trying to use custom fonts in my React Native application. I have followed many tutorials, but nothing works.

I have: - import my fonts into the "root/assets/fonts" folder (image 1) Image may be NSFW.
Clik here to view.
enter image description here

But I still get this error message:

fontFamily "Gilroy-Regular" is not a system font and has not been loaded through Font.loadAsync.
- If you intended to use a system font, make sure you typed the name correctly and that it is supported by your device operating system.
- If this is a custom font, be sure to load it with Font.loadAsync.

Amazing fact: when I build the app on xcode directly, I don't get an error message and the fonts are well used.

This error occurs when I build with expo.

Thank you a lot for your help..


Viewing all articles
Browse latest Browse all 17061

Trending Articles