Reputation: 21
I followed these instructions to add fontawsome to my react-native project. I was Able to an Icon with the example from the link
import { faCoffee } from '@fortawesome/free-solid-svg-icons'
render() {
return (
<View>
<FontAwesomeIcon icon={ faCoffee } />
</View>
)
}
How can I use other Icons? For example . I am not sure how would be the name of this icon. I tried fadFaHourglass but obviously dose not work.
Upvotes: 0
Views: 288
Reputation: 1102
Try with react-native-vector-icons
import Icon from 'react-native-vector-icons/FontAwesome';
const myIcon = <Icon name="rocket" size={30} color="#900" />;
User myIcon variable in your code.
Ref link:- https://www.npmjs.com/package/react-native-vector-icons
Upvotes: 2