react-native-modal-picker icon indicating copy to clipboard operation
react-native-modal-picker copied to clipboard

Issue with PropTypes.array

Open udarts opened this issue 8 years ago • 4 comments

I received an error about undefined is not an object (evaluating propTypes.array).

I fixed it by changing the following in the react-native-modal-picker/index.js:

import React,{
    PropTypes
} from 'react';

To:

import React from 'react';
import {PropTypes} from 'prop-types';

Which works perfectly. It seems that prop-types is a separate module in react-native, so no longer being imported from react itself.

udarts avatar Nov 08 '17 12:11 udarts

still not work for me

ducanhmai205 avatar Nov 29 '17 07:11 ducanhmai205

What error did you get?

udarts avatar Nov 29 '17 07:11 udarts

Please add soon!

dougsatch avatar Dec 12 '17 13:12 dougsatch

This repo is no longer mantained. You should therefore use the fork peacechen/react-native-modal-selector instead, which have fixed this and other issues.

mikaello avatar Dec 13 '17 13:12 mikaello