Skip to main content

Stack navigation

Our app has a handy bottom tab navigator going, but what if we want to go to a screen that's not listed there, say a modal to add a new timeEntry? For this we'll need a different kind of navigator called a Stack Navigator. Follow the installation steps in the docs to get everything ready for implementing it.

Since we'll be having two navigators in our app that enable the user to navigate between them, we'll have to 'nest' our navigators. To read a bit more about this phenomenon, check out this part of the guide.

Our objective for this chapter is to make a Stack Navigator that contains our Tab Navigator and lets us navigate from the green button in Timesheets to a NewTimeEntry modal. Check out the screen options to see how you can make your screen into a modal.