Unable to resolve “fbjs/lib/areEqual” from “node_modules\\react-native-gesture-handler\\createHandler.js”

混江龙づ霸主 提交于 2019-12-06 03:29:14

I just solved this in my project by doing npm install fbjs.

fbjs utils has the desired (and missing) "areEqual": "fbjs/lib/areEqual",

You cannot insert a component into a button. Remove components.

Home.js

    return (
      <View>
        <Text>Plan Name:</Text> 
        <TextInput style={{height: 40, borderColor: 'black', borderWidth: 0.8}}
       onChangeText={(text) => this.setState({text})}
       value={this.state.text}/>

      <Button style={{ width: 50, alignSelf: "flex-end" }}
      title="Add Plan"
      onPress={() =>
        this.props.navigation.navigate('PlanScreen')} /> 
        </View>
      )

OR You can use TouchableOpacity

import {
  TouchableOpacity
} from 'react-native'
    <TouchableOpacity onPress={() => this.props.navigation.navigate('PlanScreen')} >
        <MyDatePicker/>
        <ImageSelector/>
    </TouchableOpacity>
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!