Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined is not an object (evaluating '_react3.default.PropType.bool') #104

Open
drm-code opened this issue Oct 30, 2017 · 14 comments
Open

Comments

@drm-code
Copy link

drm-code commented Oct 30, 2017

I just install the plugin today and I got this error.

I read this https://stackoverflow.com/questions/42542540/react2-default-proptypes-function-is-undefined#answer-46434046, but I couldn't solve it, so I install the component on this one is based, and it works, but this one is easier to use, please fix the issue T_T

React: 0.49.5 ReactNativeCli: 2.0.1 OS: linux

reactnative

@eriveltonelias
Copy link

eriveltonelias commented Oct 31, 2017

You can fix it just using

yarn add https://github.com/merryjs/react-native-app-intro

issue #102

@drm-code
Copy link
Author

drm-code commented Oct 31, 2017

Thanks @eriveltonelias that worked, but now Skip and Done buttons are very closer to bullets

😭

reactnative
react

@drm-code
Copy link
Author

I'm editing node_modules/react-native-app-intro/AppIntro.js changing the default styles and I got this result, I think it's decent but it needs more job 👍

225

@eriveltonelias
Copy link

@drm-code you're welcome. :)

@giturra
Copy link

giturra commented Jan 31, 2018

@eriveltonelias thanks this worked for me too :)

@apatche7
Copy link

apatche7 commented Feb 8, 2018

that worked, but now Skip and Done buttons are very close to bullets
fixed here => #86

By adding customStyles={{ btnContainer: { flex: 1 } }}

@hhahh2011
Copy link

npm install react-native-app-intro@[email protected]:merryjs/react-native-app-intro.git --save 靠谱

@ParthBarot-BoTreeConsulting
Copy link

ParthBarot-BoTreeConsulting commented May 9, 2018

Facing the same issue but under the react-native-swiper/../index.js, can you not merge the pull request into this? I assume many people would be facing this issue while upgrading RN version

@asifvora
Copy link

simulator screen shot - iphone x - 2018-09-18 at 16 10 00

i got the error i have changes and set the ref to view.

@kukode
Copy link

kukode commented Nov 20, 2018

@eriveltonelias
cannot work im get error
undefined is not an object (evaluating RNGestureHandlerModule state

my code index.js

/** @format */

import {AppRegistry} from 'react-native';
// import App from './App';
// import Intro from './src/component/screen/IntroScreen';
import StackNavigator from './src/navigation/StackNavigator'
import {name as appName} from './app.json';

AppRegistry.registerComponent(appName, () => StackNavigator);

StackNAvigator.js

import React,{Component} from 'react';
import  {createStackNavigator} from 'react-navigation';
import IntroScreen from '../component/screen/IntroScreen';


export default (StackNavigator = createStackNavigator(
    {
      Intro: {
        path: "/",
        screen: IntroScreen
      },
      
    },
    {
      initialRouteName: "Intro",
      navigationOptions: {
        header: null
      }
    }
  ));
  

my introscreen.js

import React,{Component} from 'react';

import AppIntro from 'react-native-app-intro';
import { AppRegistry, Alert } from 'react-native';


// const styles = StyleSheet.create({
//     image : {
//         width : 320,
//         height : 320
//     }
// })



export default class IntroScreen extends Component {

    static navigationOptions = {
        header: null
      };
    
    
      onSkipBtnHandle = (index) => {
        Alert.alert('Skip');
        console.log(index);
      }
      doneBtnHandle = () => {
        Alert.alert('Done');
      }
      nextBtnHandle = (index) => {
        Alert.alert('Next');
        console.log(index);
      }
      onSlideChangeHandle = (index, total) => {
        console.log(index, total);
      }
 
    render(){

        const pageArray = [{
            title: 'Page 1',
            description: 'Description 1',
            img: '../../assets/1.jpg',
            imgStyle: {
              height: 80 * 2.5,
              width: 109 * 2.5,
            },
            backgroundColor: '#fa931d',
            fontColor: '#fff',
            level: 10,
          }, {
            title: 'Page 2',
            description: 'Description 2',
            img: require('../../assets/1.jpg'),
            imgStyle: {
              height: 93 * 2.5,
              width: 103 * 2.5,
            },
            backgroundColor: '#a4b602',
            fontColor: '#fff',
            level: 10,
          }];
        
        return(
            <AppIntro
            onNextBtnClick={this.nextBtnHandle}
            onDoneBtnClick={this.doneBtnHandle}
            onSkipBtnClick={this.onSkipBtnHandle}
            onSlideChange={this.onSlideChangeHandle}
            pageArray={pageArray}
        />
            
        )
    }
}
AppRegistry.registerComponent('IntroScreen', () => IntroScreen);

@eriveltonelias
Copy link

@kukode I think that your project is missing the react-native-gesture-handler module, so you can solve it with yarn add react-native-gesture-handler && react-native link

@kukode
Copy link

kukode commented Nov 20, 2018

yes im get error undefined is not an object (evaluating rngesturehandledmodule state

@kukode
Copy link

kukode commented Nov 20, 2018

@eriveltonelias i get
Unable to resolve module react-native-app-intro but im already install this module

@kukode
Copy link

kukode commented Nov 20, 2018

@eriveltonelias my dependenciy "react-native-app-intro": "git+https://github.com/merryjs/react-native-app-intro.git"
true or false ??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants