aName
aName

Reputation: 3053

How to find fontAwsome icon's name

I'm trying to use font-awesome icons in a react native app, therefore I installed it and imported it using react-native-vector-icons :

import Icon from "react-native-vector-icons/FontAwesome";
.....
<Icon name="map-pin" />

however I don't know where to find the name of the icons, I browsed in the font awesome web site, found some icons, but when I tried to use them, it doesn't work
for example in their website this icon's name is abacus, however, when I use it in my app, I get a warning and the icon doesn't display.

Upvotes: 0

Views: 7527

Answers (3)

Ayesh Nipun
Ayesh Nipun

Reputation: 614

You can use https://oblador.github.io/react-native-vector-icons/ to find the icon names. It has all the icons in the react-native-vector-icons library.

Upvotes: 1

Tim
Tim

Reputation: 10719

As you said, you can get the names from the official FontAwesome Webiste, but you need to be careful. There are regular icons and pro icons. The pro icons are marked with a small blue banner on the right top. By default, only the free/regular icons are available in the react-native-vector-icons package.

Regular Icon:

regular icon

Pro Icon

pro icon

As you can see, the abacus icon is a pro icon and therefore not available in the free tier.

Upvotes: 0

Charlie
Charlie

Reputation: 1042

You can get the icon names from here https://expo.github.io/vector-icons/

Upvotes: 1

Related Questions