react-native-auto-scroll | ScrollView | Frontend Framework library
kandi X-RAY | react-native-auto-scroll Summary
kandi X-RAY | react-native-auto-scroll Summary
ScrollView that scrolls down responsively.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of react-native-auto-scroll
react-native-auto-scroll Key Features
react-native-auto-scroll Examples and Code Snippets
Community Discussions
Trending Discussions on react-native-auto-scroll
QUESTION
I'm trying to call a function that will fire upon onFoucs on TextInput
that will scroll the scrollView all the way down (using scrollToEnd()
)
so this is my class component
...ANSWER
Answered 2017-Oct-17 at 14:06Rather than using a setTimeout
you use Keyboard API of react-native. You add an event listener for keyboard show and then scroll the view to end. You might need to create some logic on which input is focused if you have more than one input in your component but if you only have one you can just do it like the example below.
Another good thing to do is changing your refs to functional ones since string refs are considered as legacy and will be removed in future releases of react. More info here.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install react-native-auto-scroll
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page