A
A
Alex Krynytskyi2021-02-18 16:40:14
React
Alex Krynytskyi, 2021-02-18 16:40:14

ReactJS how to listen to scroll event?

I want the home page to listen to the scroll event, but in fact it will not scroll. Is it possible to set height 100vh and overflow scroll
but this approach does not suit me.
how can this problem be solved? Onscroll is also not suitable, since it is necessary that the event be listened to on the mobile device when scrolling, but it does not seem to work like that.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
T
t800zippygod, 2021-02-18
@NEOmanceR

You should rather listen to onTouchStart, onTouchMove events

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question