Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong Icons Showing #1602

Open
ColtraneNadler opened this issue Mar 8, 2024 · 4 comments
Open

Wrong Icons Showing #1602

ColtraneNadler opened this issue Mar 8, 2024 · 4 comments

Comments

@ColtraneNadler
Copy link

Environment

IOS

Description

Wrong icon is displayed, or not at all.

import Icon from 'react-native-vector-icons/MaterialIcons'

const Component = () => (<View> 
     <Icon name="play-arrow" color="#000" />
</View>

this displays
94c8f7a6bdc15f72db990a350c5ed6ea (1)

I have tried reinstalling. Cleaning build folder.

    "react": "18.2.0",
    "react-native": "0.73.5",
    "react-native-safe-area-context": "^4.9.0",
    "react-native-screens": "^3.29.0",
    "react-native-sound": "^0.11.2",
    "react-native-vector-icons": "^10.0.3"
@alordiel
Copy link

I had something similar. I had to check my /android/app/build.gradle : and look into the end of the file:

project.ext.vectoricons = [
    iconFontNames: [ 'MaterialCommunityIcons.ttf' ]
]
apply from:file("../../node_modules/react-native-vector-icons/fonts.gradle");

This is how my file looks now. In my case I was missing MaterialCommunityIcons and had Ionicicons or whatever was its name.

@tarangshah19
Copy link

can you please tell me react-native-vector-icons/MaterialIcons working on ios or not? i am trying since last week not able to use react-native-vector-icons/MaterialIcons in ios

@alordiel
Copy link

alordiel commented Apr 1, 2024

I am developing only for Android and haven't built anything for iOS (yet). But from the other issues I'm seeing there might be some problem with newer versions and iOS #1604. I am using "react-native-vector-icons": "10.0.3", "react-native": "0.73.6", "react": "18.2.0" without expo. Not sure if using those save versions will do the trick for you.

@ColtraneNadler
Copy link
Author

i am having the issue in ios environment .... react-native 0.72.6 and 0.73.*

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants