xgfe / react-native-datepicker

react native datePicker component for both Android and IOS, useing DatePikcerAndroid, TimePickerAndroid and DatePickerIOS
MIT License
2.12k stars 726 forks source link

Fixed componentWillReceiveProps warning #362

Open alexnaiman opened 5 years ago

alexnaiman commented 5 years ago

Fixed componentWillReceiveProps warning Issue #355

coveralls commented 5 years ago

Coverage Status

Coverage remained the same at 97.368% when pulling d722086c6c6f96b17338f48a7b209e47161a751d on alexnaiman:fix_for_react_warning into 2a209bd4f11a84ff4543fbde930fed60dcbc0f68 on xgfe:master.

ramonvermeulen commented 5 years ago

Please merge this, want to get rid of the warning message.

dj1993cse commented 4 years ago

Warning: componentWillReceiveProps is deprecated and will be removed in the next major version. Use static getDerivedStateFromProps instead.

Please update the following components: DatePicker

Learn more about this warning here: https://fb.me/react-async-component-lifecycle-hooks console.warn @ D:\React_Native\DatePickerApp\node_modules\react-native\Libraries\YellowBox\YellowBox.js:71

cesar3030 commented 4 years ago

+1 to merge this PR

ramonvermeulen commented 4 years ago

@feyy

Is it possible to make a new release including this merge request? Package hasn't received any release since April 2018 while there are a lot of open merge requests with good code.

Maybe unpopular opinion: If you don't have the time to maintain the library, please try to find someone who does.

alexnaiman commented 4 years ago

@ramonvermeulen

@feyy If you don't have the time to maintain the library, please try to find someone who does.

I really agree with you and I will be really grateful if I can do that or at least be a part of that

mieszko4 commented 4 years ago

This looks like a dead project without maintainer :( I think it is time to either:

  1. look for an alternative, e.g. https://github.com/react-native-community/react-native-datetimepicker
  2. fork this repo and publish it under new name in npm registry
ramonvermeulen commented 4 years ago

@mieszko4 at our company we went to the react-native-community version as well. Way better maintained.

YahiaBadr commented 4 years ago

This looks like a dead project without maintainer :( I think it is time to either:

  1. look for an alternative, e.g. https://github.com/react-native-community/react-native-datetimepicker
  2. fork this repo and publish it under new name in npm registry

did you do it? If yes, then please share the new npm-package.

stianjensen commented 4 years ago

This looks like it might be a good and maintained alternative, that solves the same issue as this project originally did: wrapping the core ios and android datepicker components from react native in a nice crossplatform api: https://github.com/mmazzarolo/react-native-modal-datetime-picker

It is wrapping the extracted versions in https://github.com/react-native-community/datetimepicker/issues rather than the deprecated ones that ship with react native core that this library does.

YahiaBadr commented 4 years ago

I made this package https://www.npmjs.com/package/react-native-datepicker-yaya only to solve the warning of the componentWillReceiveProps. Everyone is welcomed to use it instead of this package.

GabrielDvt commented 4 years ago

PLEASE MERGE!