I've tried to import like those below:
// import Icon from 'react-native-vector-icons/dist/FontAwesome';
// import Icon from 'react-native-vector-icons/FontAwesome';
import Icon from 'react-native-vector-icons/Ionicons';
all comes up 'Unrecognized font family XXX'
none is useful, how to import Icon?
"dependencies": {
"@babel/core": "^7.0.0-beta.40",
"eslint": "^3.19.0",
"react": "16.3.1",
"react-native": "0.55.3",
"react-native-vector-icons": "^4.6.0",
"react-navigation": "^1.5.11"
},
Hi, @lafayea. Try drag the _Fonts_ folder to the Project in xCode.
I have the same issue, I have tried doing everything mentioned in the Manual mode but failed so I have created new project, installed package, and installed rnpm
even after that I am getting the error, Please someone help me get this resolved
Code :
import React from 'react';
import { StyleSheet, Text, View } from 'react-native';
import Icon from 'react-native-vector-icons/Ionicons';
export default class App extends React.Component {
render() {
return (
);
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'center',
justifyContent: 'center',
},
});

@davekedar run react-native link react-native-vector-icons, and after the run link command, run this command:
watchman watch-del-all && npm start --reset-cache, and try run on simulator again.
Got the same error. But solved finally.
After adding that plist, you still need to add those fonts to Building phase, in my case, I thought the Cocopods installation will copy it, seems I am wrong. After adding them, the error is gone.
I am having this issue, i added the Fonts in xcode and i see them in the bundle phase and still getting same error
Please i got this error more than 1 month,
I have tried to drag the fonts folder to xCode & i have tried more things but still seeing the error..
first clean the node_modules folder, then reinstall and also link
rm -rf node_modules
npm i
react-native link
then from xcode clean and then build for the ios project and run it in the simulator from xcode itself.
In my case, the problem was the my iOS build failed because it couldn't locate the Fonts folder. Seems I moved/cut it from the node_modules folder into Xcode instead of copying it. Just be careful when following the instructions which tell you to drag the Fonts folder from Finder into the Xcode project.
If anyone else still has this issue please try running the project with Xcode, or with _react-native run-ios_
Still facing this error more than 3 months i have tried all things, Please can someone help me to fix this please, I'm so confused.
the most screens of my application are using native-base :/
Also - Im using Visual Studio Code & windows device.
Please Advice !!
@Yassir4 I'm not using mac os what i should to do in this case ?
I'm gonna close this one as it's not a problem with the library, but with the integration from the user. Problems faced in this thread are heterogenous as are the solutions, but all should be outlined above and in the README.
This should be reopened.
No it should not 馃槉 Pleas follow the instructions in the readme and open a PR if they could be improved in any way.
Well I've done that so I will open a new Issue. I don't get an error when I run xcode build, but I do get an error when I run react-native run-ios. See current open issue for it. Very relevant to many users of the package now. #945
I have the same issue, i follow all the step of setting up manually.
"dependencies": {
"react": "16.8.3",
"react-native": "0.59.9",
"react-native-navigation": "^2.21.0",
"react-native-vector-icons": "^6.5.0",
"react-redux": "^7.1.0",
"redux": "^4.0.1"
},
import Icon from "react-native-vector-icons/Ionicons"
@genegr88, try again after downgrading react-redux to @6
I had two build phases trying to copy over the same files twice, I deleted one
I got this error "Unrecognized font family 'Ionicons'" and then, I went to my xcode > myproject > info.plist > Fonts provided by application and add all the vectors icon manually; AntDesign.ttf, FontAwesome.ttf, Ionicons.ttf, etc. After that, I run my project and the error gone.
@samchidi2005
fuck i have the same issue
Most helpful comment
@davekedar run
react-native link react-native-vector-icons, and after the run link command, run this command:watchman watch-del-all && npm start --reset-cache, and try run on simulator again.