In the React part of this book, we built a complete routing solution, including public and protected routes, using a login view to enter the user's name and password. In a mobile application, since the user is more restricted, we can just make do by enabling a login at the beginning, and enabling the normal navigation afterward. All the work with usernames, passwords, and tokens is basically the same as before, so for now, let's only worry about navigation, which is different in RN, and forget the common details.
For starters, let's have some views—a empty screen with some centered text will do:
// Source file: src/routingApp/screens.js/* @flow */import React, { Component } from "react";import { Button, Image, StyleSheet, ...