New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using icons #323
Comments
You should import your icon directly from this package like this: import Icon from 'react-native-vector-icons/EvilIcons'; |
Now none of the icons from other packages won't work. I'm trying to have header like here http://nativebase.io/docs/v0.5.9/components#header and also use icons from other packages, not just limiting to one. |
Think I got it.
Then instead using |
According to the IconNB implementation:
|
Is the aforementioned thing possible to get around with, some aliasing on part of the user? Namespace clash then with the icons' names themselves? Just thinking of "going simple" and keeping downstream code consistent. The idea would be that "just use the icons", without - as a developer - caring about exactly in which packages they are implemented. I thought along the lines: // Combines packages here somehow, after which: I'd be interested in making some kind of PR if this is deemed |
Try upgrading your semantic-ui-react version to latest version |
|
Following docs how to use icons in native-base project didn't help me to use any icon other than the ones from Ionicons package.
I installed react-native-vector-icons and linked with rnpm.
Here I see all icon definitions in my project: node_modules/native-base/node_modules/react-native-vector-icons/
If I want to use any other icon, for example "arrow-right" from EvilIcons, I'm getting in my Genymotion emulator: "Warning: Failed prop type: Invalid prop 'name' of value 'arrow-right' supplied to 'Icon', expected one of ['ios-add', 'ios-add-circle', .....]"
All these expected icons are defined in Ionicons.js file.
So, how do I get "arrow-right" from EvilIcons package?
Right now I'm doing like this:
<Icon name='arrow-right' />
Thanks!
The text was updated successfully, but these errors were encountered: