-
Notifications
You must be signed in to change notification settings - Fork 24.4k
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
UIScrollView : paging horizontally, scrolling vertically ? #1315
Comments
Nested scroll views is the correct approach but unfortunately they don't work very well with React right now (#41). |
I just want to know how to solve it ? |
You could create a native UIPageViewController or native UIScrollView and create a separate RCTRootView (that all share the same RCTBridge) for each screen. I don't think there's a good way to do this with pure React right now. Either you run into issues with nested scroll views or you have to reimplement the scroll physics which was kind of janky in the one example I saw. |
ok, I see. It is not easy to finish it . I don't know much about object-c. |
I also want to know how to change the scrollView's props like |
I change the
But it doing nothing . It can't prevent the ScrollView to be a responder. |
I have solve it . |
@soliury Great! Maybe you can share your solution for other people that might come across this! |
Just don’t set the contentStyle width and height, so it will work.
|
I am writing a app in react-native, and then I will open the source of app, When the day come, I will put the example to here.
|
The solution is that , don't set the This is my app writing in react-native, after I finish it, I will open source. |
@soliury - looks nice! would like to see it when the open source version is available. thanks for the follow up! |
@brentvatne I have open source. Just see https://github.com/soliury/noder-react-native, But the code is not clear, I will refactor it soon. |
Nice one @soliury! |
I just want to know how to set the [UIScrollView : paging horizontally, scrolling vertically], I mean I have a scrollView, and then I set the props 'pagingEnabled' to
true
. But it working in horizontally, but I don't want the horizontally to be paging.How can I solve it ?
I have tried this:
I set a nest scrollView, the wrapper one set the
pagingEnabled
totrue
, when I scrolling , the inner one don't respond the scrolling , and the wrapper one have respond, How can I let the wrapper one don't handle the scroll event, and let the inner one handle the event?The text was updated successfully, but these errors were encountered: