react-native-vector-icons: Icons not being displayed
Hi,
I’m trying to use xotahal/react-native-material-ui module but icons doesn’t seem to work. I’m opening the issue here, because I can’t make icons appear even when using basic example:
import Icon from 'react-native-vector-icons/FontAwesome';
const myIcon = (<Icon name="rocket" size={30} color="#900" />)
I’ve checked all steps of installation guide and everything seems to be correct, I’ve also tried steps from troubleshooting, but still nothing. It looks like the icon is being rendered because if I add the onPress prop it will be activated properly, but icon is not displayed and I can’t see it.
Could you please help me find out what could be causing this problem?
Environment details:
- Windows 10
- Android 4.1.2 (testing on real device)
- React Native 0.43
- react-native-vector-icons 4.1.0
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 17
Hi, I spent so many hours and found the answer here #https://github.com/GeekyAnts/NativeBase/issues/138 Run
react-native link& thenreact-native run-android+1
Never mind! https://github.com/oblador/react-native-vector-icons/issues/449#issuecomment-298396164 had worked for me.
After several desperate tries of removing and reinstalling node_modules and running
react-native run-androidI can finally see icons. 😄Once after installing the module, link it to the project.
react-native link react-native-vector-icons
write this command
react-native link
this command will download fonts of react native vector icons in both of android and ios then the icons will show
On Sat, Nov 2, 2019 at 11:58 AM faysalJadoon notifications@github.com wrote:
God bless u man