question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

react-native-elements - vector icons

See original GitHub issue

It seems like create-react-native app has some issues with “react-native-elements”. I’ve tried 2 scenarios which both produces the same error:

Test 1

  • created a new project with create-react-native-app
  • npm i react-native-elements --save
  • Added a react-native-elements button in App.js
  • npm run ios

Test 2

  • created a new project with create-react-native-app
  • npm i react-native-vector-icons --save && react-native link react-native-vector-icons
  • npm i react-native-elements --save
  • Added a react-native-elements button in App.js
  • npm run ios

In both test the simulator throws this warning. I’ve tried to run the commands described in the error message, but with no luck 😦

screen shot 2017-03-14 at 11 02 39

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:6
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

5reactions
brentvatnecommented, Mar 14, 2017

Hello! Thanks for catching this, we’ll add ttf as a default support asset extension in our next release this afternoon.

See this repo for a working example of react-native-elements: https://github.com/exponent/elements-example-crna

The most important part is this: https://github.com/exponent/elements-example-crna/blob/master/app.json#L4-L6 – if you add it to your app.json and restart the packager (necessary to pick up the changes to the packager options) it should work

1reaction
anpcommented, Mar 14, 2017

Hi! Thanks for the report. We’re working on making it easier to use these transparently in CRNA.

If you first install https://www.npmjs.com/package/@expo/vector-icons and then try using react-native-elements, this should work for you. Note that if/when you eject to a regular RN project, you’ll need to switch from Expo’s vector icons to the regular react-native-vector-icons.

Let me know if that resolves your immediate issue. In the near future we hope to resolve this more transparently for users.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Icon - React Native Elements
The icon sets in React Native Elements are made possible through react-native-vector-icons. The current list of available icons sets are:.
Read more >
react-native-vector-icons directory
AntDesign · stepforward · stepbackward · forward · banckward · caretright · caretleft · caretdown · caretup.
Read more >
react-native-vector-icons - npm
Customizable Icons for React Native with support for NavBar/TabBar, image source and full styling.. Latest version: 9.2.0, last published: 6 ...
Read more >
oblador/react-native-vector-icons - GitHub
Customizable Icons for React Native with support for image source and full styling. - GitHub - oblador/react-native-vector-icons: Customizable Icons for ...
Read more >
Example to Use React Native Vector Icons
Create a new React Native project · Install the Dependency (react-native-vector-icons) · Install CocoaPods · Importing Icon Files in Android · Importing Icon...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found