Search code examples
react-nativereact-native-elementsreact-native-vector-icons

Unrecognized font family Material Icons?


Iam new to React-Native, I have added react-native-vector-icons library manually to Xcode and Android studio. if run the code with Xcode its executing successfully without any issue. but if i trying to run the code from Terminal (react-native run-ios) its showing 'Unrecognized font family Material' in simulator. but the same this working if i runs the command (react-native run-android).

please help me. this is the error showing in terminal Error Screen shot

** BUILD FAILED **


The following build commands failed:

    CompileC /Users/user/Documents/Test/JobsNProfiles/ios/build/Build/Intermediates.noindex/RNVectorIcons.build/Debug-iphonesimulator/RNVectorIcons.build/Objects-normal/x86_64/RCTFont+FA5.o /Users/user/Documents/Test/JobsNProfiles/node_modules/react-native-vector-icons/RNVectorIconsManager/RCTFont+FA5.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Solution

  • I am not sure what exactly you are missing in your configuration, so I am gonna state all what I believe is the case:

    1. Delete ios/build folder, then try automatic linking: react-native link react-native-vector-icons.

    2. Make sure you have checked that the font is copied in the Copy Bundle Resources in Build Phases. If not, re-check the manual configuration steps.

    3. Make sure you kill the packager and re-run for changes to take effect.