react-native-datepicker icon indicating copy to clipboard operation
react-native-datepicker copied to clipboard

Warning: componentWillReceivedProps has been renamed and is not recommended for use

Open iamraju opened this issue 4 years ago • 4 comments

Issue

componentWillReceivedProps has been renamed and is not recommended for use

Expected Behavior

It should work without any warnings ?

Code

<DatePicker
              style={{width: 200}}
              date={this.state.date}
              mode="date"
              placeholder="Select Date"
              format="YYYY-MM-DD"
              confirmBtnText="Confirm"
              cancelBtnText="Cancel"
              customStyles={{
                dateIcon: {
                  position: 'absolute',
                  left: 0,
                  top: 4,
                  marginLeft: 0
                },
                dateInput: {
                  marginLeft: 36
                }
                // ... You can check the source to find the other keys.
              }}
              onDateChange={(date) => {this.setState({date: date})}}
            />

Also I got another warning that it has been merged to DatePickerIOS and will be removed in the future. Does that mean we cannot use it for Android anymore ?

iamraju avatar May 10 '20 06:05 iamraju

datepicker.zip Try the attached file I created pull request to merge with master

asibrahim1985 avatar May 18 '20 19:05 asibrahim1985

@asibrahim1985 Thanks. But another warning still presents. "Warning: DatePickerIOS has been merged with DatePickerAndroid and will be removed in a future release. It can now be installed and imported from '@react-native-community/datetimepicker' instead of 'react-native'. See https://github.com/react-native-community/react-native-datetimepicker"

VovaChampion avatar May 22 '20 10:05 VovaChampion

why this plugin is not updating?

s4sebin avatar May 27 '20 06:05 s4sebin

Any help with this warning?

dobradovic avatar Sep 02 '20 10:09 dobradovic