Обнаружена ошибка «RNGestureHandlerModule.State» с React Navigation - PullRequest
0 голосов
/ 08 декабря 2018

Я новичок, чтобы реагировать на родных.При реализации реакции навигации я сталкиваюсь со странной проблемой.Я получаю сообщение об ошибке на симуляторе iOS: «undefined не является объектом» (оценивается «RNGestureHandlerModule.State»). Нигде в приложении не используется распознаватель жестов.

export default class App extends Component {
  render() {
    return (
      createStackNavigator({
        Home: {screen: HomeScreen},
      })
    )
    }
}

HomeScreen - это простой класс:

export default class HomeScreen extends Component {
    render() {
        return(
            <View>
                <Text style={{marginTop: 80}}>Thi sis test</Text>
            </View>
        );
    }
}

Я использую CLI с встроенной реакцией. При установке реакции навигации я получаю несколько предупреждений

ankur:MyGithub ankurprakash$ cd /Volumes/Glen/MyGithub/navigationSample 
ankur:navigationSample ankurprakash$ npm install --save react-navigation@latest
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/sane as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/sane
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/uuid as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/uuid
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/json5 as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/json5
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/jsesc as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/jsesc
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/jest as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/jest-cli
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/esparse as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/esprima
npm WARN rm not removing /Volumes/Glen/MyGithub/navigationSample/node_modules/.bin/esvalidate as it wasn't installed by /Volumes/Glen/MyGithub/navigationSample/node_modules/esprima

1 Ответ

0 голосов
/ 08 декабря 2018

Попробуйте один раз:

  1. удалить node_modules и package-lock.json
  2. npm установить
  3. npm установить - сохранить реакцию-навигацию
  4. npm install --save реактивный родной жест-обработчик
  5. реактивный родной канал
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...