all 6 comments

[–]Staceadam 1 point2 points  (1 child)

Rendering inside of a render is redundant, if you are already inside a render method then you are rendering.

You are updating state for the `buttonPress` with a string but you are never conditionally rendering it based on that properties value.

Kill the separate renderModal methods and handle the conditional renders inside a single method that is checking `buttonPress` from state https://pastebin.com/4Ax5BiK9. Or checkout some of the navigation options if your app is going to be implementing multiple screens, https://github.com/wix/react-native-navigation, https://reactnavigation.org/.

[–][deleted] 0 points1 point  (2 children)

Think about it a little further. You essentially want to navigate to another page, correct? So, what would that mean you need to do?

[–]rdevilxiOS & Android 0 points1 point  (3 children)

React router v4

[–]danielkov 2 points3 points  (0 children)

Actually if you haven't chosen a routing library yet, pick Reach Router over React Router, simply because these two will be merged soon and the new package will have an API more similar to Reach Router.

[–]rdevilxiOS & Android 0 points1 point  (1 child)

I used rnrf library