This question has been already here and here, but the answer is not satisfactory there. The fonts are not working on android but on iOS do. Maybe I made some mistake during the linking.
How did I added fonts:
- Created folder
assets/fonts/
inside root folder. Added
"rnpm": { "assets": ["./assets/fonts"] }
react-native link
Console output was it successfully added assets to iOS and Android
Added fontFamily: 'MyCustomFontFamily' into styles.
Run on iOS, everything worked fine.
Run on Android, no typeface.
Checked the android project directory and the assets folder was present
I tried adding
(Platform.OS === 'ios') ? 'MyCustomFontFamily' : 'fonts/my_custom_font_family'
to go with the file name but this did not work wither.Tried same variation as 9 without path or with extension but no luck
Read here to use weight, tried it, no luck.