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

"Value" prop is declared by you, when we try to assign value it shows error "this.updateSearch is not a function" #30

Open
hussainhspl opened this issue Sep 23, 2019 · 4 comments

Comments

@hussainhspl
Copy link

hussainhspl commented Sep 23, 2019

WhatsApp Image 2019-09-23 at 2 47 42 PM
I have using two search input on same page and i want to reset both input on a single reset button click. So i am trying to assign empty state to search input using value prop. Is there any other solution available ? Please Help
Thank you

@khuongphp
Copy link

I also got this issue when update expo sdk from 33 to 35

@ahmed-ismail-nt
Copy link

If you're getting this error because you're still using the hacky workaround of setting value and then clearing it when the clearIcon is pressed, then try using the defaultValue prop instead of value.

@Makbar30
Copy link

For me, i fix it with this way
Go to your node-modules/react-native-search-filter/src/index.js
Comment function getDerrivedStateFromProps
because when i console.log the value, it value all undefined although i pass a value as props , so const e is undefined

Sorry for my bad english
Hope can fix this issue

@gina-shin
Copy link

I did notice that if I change this from getDerivedStateFromProps() to UNSAFE_componentWillReceiveProps() it seems to work for my use case...

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

No branches or pull requests

6 participants