react-native-vector-icons not working on web
HeaDBanGer84 opened this issue · 2 comments
HeaDBanGer84 commented
Enviroment:
- template version : (0.x.x) no clue how to find out...the version from yesterday
- react-native-vector-icons: (4.4.2),
- react-native version: ("0.50.3)
- OS : Linux
- Platform causing error: web
Step 3: Describe the problem (try to include screenshots):
Try to include react-native-vector-items, which works pretty well on android, but not on the web. Seems that the fonts are not bundled correctly with the webpack.config (neither Production nor dev). I searched my ass up to find the configs in the react-scripts module and try to added the needed loader but didn't work.
Your template is really awesome so perhaps you guys could help me/fix this, because you mentioned rnvi on your readme and i think it is a very usefull asset lib.
Steps to reproduce:
- create a new project, as discribed in Readme.md
- yarn add react-native-vector-icons
- added an icon in TopLevelScreenComponent.js
//...
import Icon from 'react-native-vector-icons/dist/MaterialIcons';
...
render() {
//...
<Icon.Button name = "image"
backgroundColor = "#a41010"
onPress = {this.props.failDispatchedAction} >Test Icon Button </Icon.Button>
//...
Observed Results:
no errors just the font could not be loaded (on web...on android ...perfect)
Expected Results:
a button with an icon
HeaDBanGer84 commented
raimens commented
I'm struggling with too :( :( :( or may I can say stuck