TypeError: undefined is not an object (evaluating ExpoFontLoader.loadAsync)

Viewed 2038
import React, { Component } from 'react';
import { 
   View, 
   TextInput,
} from 'react-native';
import Icons from 'react-native-vector-icons/FontAwesome';

class EmployeeFrom extends Component {
 render() {
   return (
     <View>
       <View>
         <Icons name="user" size={28}
         style={styles.InputIcons}
         />
         <TextInput style={styles.textInput} 
                placeholder="Name"
                placeholderTextColor="black"
                underlineColorAndroid="rgba(0,0,0,0)"
         />
       </View>
      </View>
    );
   }
  }

I imported the vector Icons form react-native-vector-icons but still I'm getting the error can any one please help me

1 Answers

I had the same problem.

I was helped to level the versions of the expo and the version.

It was:

package.json

"dependencies": {
  "expo": "^30.0.1",
  "react-native": "https://github.com/expo/react-native/archive/sdk-29.0.0.tar.
}

app.json

"expo": {
  "sdkVersion": "29.0.0",
}

It became:

package.json

"dependencies": {
  "expo": "^30.0.1",
  "react-native": "https://github.com/expo/react-native/archive/sdk-30.0.0.tar.
}

app.json

"expo": {
  "sdkVersion": "30.0.0",
}
Related