React Native undefined is not an object (evaluating 'RNGestureHandlerModule.State')
前言:
- 當使用RN開發跨平臺app時,使用的元件(如,react-navigation...),這個元件可能是需要連結原生庫的。就是說要使用react-native link
- 如使用到需要連結原生庫,而沒有 react-native link,執行時報:undefined is not an object (evaluating 'RNGestureHandlerModule.State')
環境:
- Mac OSX
- Intellij IDEA
- Jdk 1.8x
- React-native-cli:2.0.1
- React-native:0.57.6
- npm:6.4.1
- node:v11.2.0
Code:
當前專案根目錄下如下命令:
➜ react-native link
停止包管理伺服器(關閉命令視窗,或者ctrl + c),
重新執行專案:
➜ react-native run-ios
或
➜ react-native run-android
稍等片刻...
working for you?
相關推薦
React Native undefined is not an object (evaluating 'RNGestureHandlerModule.State')
前言: 當使用RN開發跨平臺app時,使用的元件(如,react-navigation...),這個元件可能是需要連結原生庫的。就是說要使用react-native link 如使用到需要連結原生庫,而沒有 react-native link,執行時報:undefi
react-native 編譯報錯: undefined is not an object (evaluating '_react2.PropTypes.func')
情況通報: 因為是我的二維碼模組報錯,提示報錯程式碼如下 重要資訊是下面的紅色字型部分(Android 模擬器紅屏) undefined is not an object (evaluating '_react2.PropTypes.func')<unknown> D:\CDM_POS_AP
react-native 編譯 undefined is not an object (evaluating '_react2.PropTypes.func')
情況通報: 因為是我的二維碼模組報錯,提示報錯程式碼如下 重要資訊是下面的紅色字型部分(Android 模擬器紅屏) undefined is not an object (evaluating '_react2.PropTypes.func')<unknown> D:\CDM_POS_AP
解決React Native報錯:undefined is not an object (evaluating 'sceneConfig.animationInterpolators')
呼叫this.props.navigator.resetTo出現以下問題 undefined is not an object (evaluating ‘sceneConfig.animationInt
React Native 出現undefined is not an object (evaluating 'this.props.navigator')
在RN的元件裡面,我們想進行介面跳轉,網上查閱資料,配置程式碼實現如下, <NavigatorIOS ref='nav' style= {styles.container}initialRou
執行React Native示例出現null is not an object (evaluating 'this.state.text')
在執行官方示例的時候出現了null is not an object (evaluating 'this.state.text'),明明是直接copy的,state初始化也是根據ES6來的,怎麼就突然報錯了,很尷尬... 一開始以為是跟安卓版本相關,6.0行,4.4.4有b
RN中文網中電影專案出現的問題 TypeError:undefined is not an object(evaluating'e.posters.thumbnail')
TypeError:undefined is not an object(evaluating'e.posters.thumbnail') This error is located at: in t inRCTView int RCTSrollView int ScrollView
ReactNative 打的release包閃退之——undefined is not an object (evaluating 'a.View.propTypes.style')?
寫在前面: 這個問題巨坑一個,足足花了我2天時間。 現象描述: 使用react-native run-android 命令打的包能正常安裝在模擬器上執行,一切都是那麼的平靜。然而,我使用gradlew assembleRelease命令打出的生產
[ReactNative]undefined is not an object (evaluating 'ImagePickerManager.showImagePicker')
最近用到ImagePicker,在Android上面可以正常選擇圖片,但是IOS程式就崩潰了。 首先說明一下,一定自己配,別去link!!! !!! 一定自己配,別去link!!! !!! 一定自己配,別去link!!! !!! 下面說一下XCode怎麼解決: 1.按照圖
undefined is not an object (evaluating 'dataSource.rowIdentities')
在寫listview的時候出錯,怎麼查都找不到原因,最終發現太粗心了,listview的閉合部分寫錯了! <ListView dataSource = {this.state.dataSource.cloneWithRows(this.state.data
undefined is not an object (evaluating 'this.props.nav.push')的解決過程
說明:剛接觸react native不到兩個星期,這兩天在做頁面跳轉的時候遇到了這個問題(頭疼了兩天)。剛剛終於解決了,先把解決過程記錄下來 1、當前react native的最新版本是0.47,因
undefined is not an object (evaluating '_react3.default.PropTypes.bool')
在學習React Native的過程中,也就是學習生命週期defaultProps()的時候,為defaultProps配置屬性和為屬性申請型別時出現錯誤 static defaultProps =
undefined is not an object (evaluating 'this.props.navigator.push')
在通過navigator 進行頁面跳轉的過程中 一直報 這樣的錯誤 先看程式入口檔案index.android.js import React, { Component } from 'react'; import { AppRegistry, StyleShee
在TabNavigator中使用Navigation報錯undefined is not an object (this.props.navigation.navigate)
在學習react-native時,出現一個愣是想不明白的錯誤,在TabNavigator底部導航選單的子頁面中做跳轉,總會彈出錯誤介面,錯誤大概: 即是這個屬性是不存在的。想想,可能需要在導航選單頁裡傳遞一個名為navigation的引數才行吧,於是在首頁的底部選單每個子
React Native報錯unddefined is not an object(evaluating ‘_reactnative.propTypes’)解決辦法
報錯截圖 原程式是這樣寫的,然後一直出現錯誤,找不到PropTypes, import React,{Component } from 'react'; import { View,
React Native ListView的Item設定點選事件時null is not an object
先貼下程式碼: <ListView contentContainerStyle = {styles.list}
iOS XXXXX is not an object file (not allowed in a library)
以libsqlite3.tbd 為例 1.將下圖標註的路徑複製下來 2.根據路徑找到相應的檔案 “commend + shift + G”進入資料夾 3.新增一遍
'react-scripts' is not recognized as an internal or external command
ins ima 目錄 star nod zed png alt intern React項目在執行npm start的時候報下面的錯誤: 解決辦法:把項目目錄中node_modules文件夾刪掉,重新npm install一下,然後再執行npm start 'r
react:undefined is not a function(this.State({flag:true,}))
今天在寫react的時候遇到這個問題,就查了一下了解了原因和解決方法: 問題程式碼: class TestQRAndroidExample extends React.Component{ constructor(props) { super(props);
NiceFish的ERROR in AppModule is not an NgModule問題
type png angular 項目 問題 cnp 版本 pmo all 大漠老師的angular2新手教程項目,nicefish剛開始下下來運行ng serve --prod --aot 是 出現ERROR in AppModule is not an NgModule