Giter Site home page Giter Site logo

Comments (25)

lai32290 avatar lai32290 commented on May 3, 2024 9

I fix this issue like this step:

  • switch react-native to react-native-cli.
    $ npm uninstall -g react-native
    $ npm install -g react-native-cli

  • installing react-native-elements
    $ npm install -S react-native-elements

  • installing react-native-vector-icons
    $ npm install -S react-native-vector-icons

  • link it to project using react-native link
    $ react-native link react-native-vector-icons

  • restarting development server
    $ npm start

  • rebuild project
    $ react-native run-android

and that's it! I hope to help you

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024 6

@Java-Jonas You can go the repo of the icons: https://github.com/oblador/react-native-vector-icons#android here they tell you what to do to copy the fonts in the device.

from react-native-elements.

raduflp avatar raduflp commented on May 3, 2024 3

I was having a similar issue, then I realized I didn't reinstall the app after adding react-native-vector-icons. So a simple react-native run-android fixed it for me.

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024 2

Thanks, glad you got it fixed. Quick note, I noticed that the avatar is not rendering as a circle correctly for some reason. I'm taking a look at this now and will be releasing a fix for this along with some other stuff tonight. @mtzaldo

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024 1

Yes, I just pushed the code:

https://github.com/mtzaldo/react-native-redux-example

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

Hey. What version of react-native are you using? Also, did you get any errors when installing the library? Finally, did you restart the packager after installing it? Thanks.

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

@Java-Jonas Any luck with this?

from react-native-elements.

jobergner avatar jobergner commented on May 3, 2024

my dependencies:
"dependencies": {
"react": "15.3.1",
"react-native": "0.33.0",
"react-native-elements": "^0.4.0",
"react-native-vector-icons": "^2.1.0"
}

restarted everything, still not working. no errors. :(

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024

I have the same issue, running an example on Android, instead of the icon it displays a square with an X ... here are my dependencies:

"dependencies": {
"isomorphic-fetch": "^2.2.1",
"react": "15.2.1",
"react-native": "0.31.0",
"react-native-elements": "^0.4.2",
"react-native-vector-icons": "^2.1.0",
"react-redux": "^4.4.5"
}

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

Ok, looking into this now. @Java-Jonas Are you also having this issue on Android, or are you using iOS? cc @mtzaldo

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

Any way I can see your component declarations @mtzaldo @Java-Jonas ? Thanks.

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

@mtzaldo is ListItem the component that's giving you an issue with the icon?

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024

@dabit3 Yes, that is the one that is not displaying the right-chevron.

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

screen shot 2016-09-13 at 4 48 26 pm

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

Very interesting, I'm getting it working for some reason. Are there any errors in your console?

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024

@dabit3 No, I think I could be my emulator. For some reason the font is not being displayed correctly. I thing the issue is not with your components.

screenshot from 2016-09-13 16-56-32

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

Have you tried using only the react-native-vector icons in your project? It sounds like it could be an issue with that library being installed correctly, as is often the case I think. @mtzaldo

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024

I will review the library. It is the first time I try it, maybe I need to tweak something. Thanks @dabit3

from react-native-elements.

dabit3 avatar dabit3 commented on May 3, 2024

@mtzaldo Ok cool, let me know if you have any more questions!

from react-native-elements.

mtzaldo avatar mtzaldo commented on May 3, 2024

@dabit3 Yes, I was missing some lines in android/app/build.gradle. The icons are now being displayed correctly. Thanks again. Great project btw!

from react-native-elements.

jobergner avatar jobergner commented on May 3, 2024

@mtzaldo can you explain me what exactly you did to fix this problem? i really need those icons to work! :(

from react-native-elements.

xstable avatar xstable commented on May 3, 2024

Same for me like for @raduflp... but I've reinstalled the app.
But anyway I do it again, Kill the App-Process at the emulator and restart the app. Now Icons appear.
😕

from react-native-elements.

SOftEngrAtta avatar SOftEngrAtta commented on May 3, 2024

@lai32290 working after following your instructions (y)

from react-native-elements.

lai32290 avatar lai32290 commented on May 3, 2024

@SOftEngrAtta that's cool! I'm happy for this! 😄

from react-native-elements.

romandr25 avatar romandr25 commented on May 3, 2024

Please put it in the "getting started" section.

For me helped:

Android
Option: With Gradle (recommended)
This method has the advantage of fonts being copied from this module at build time so that the fonts and JS are always in sync, making upgrades painless.

Edit android/app/build.gradle ( NOT android/build.gradle ) and add the following:

apply from: "../../node_modules/react-native-vector-icons/fonts.gradle"
To customize the files being copied, add the following instead:

project.ext.vectoricons = [
iconFontNames: [ 'MaterialIcons.ttf', 'EvilIcons.ttf' ] // Name of the font files you want to copy
]

apply from: "../../node_modules/react-native-vector-icons/fonts.gradle"

from here https://github.com/oblador/react-native-vector-icons#android

from react-native-elements.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.