How to solve "Error: icon not found for icon = null"?

Viewed 335

Am trying to use an icon from FontAwesom library with React-Native, and this is the import statement:

import { FontAwesomeIcon } from '@fortawesome/react-native-fontawesome';
import { faLock,faAirFreshener,faAnchor, faUserLock } from '@fortawesome/free-solid-svg-icons';

And this is the code where I used it:

     <View style={styles.iconContainer}>
        <FontAwesomeIcon icon={faUserLock} size={40} color={"white"} />
     </View>

When I run the code, the icon appear, but with this error attached in image! Error image Note: am using react-native CLI, not expo!

How to solve it?

0 Answers
Related