expo-router-template
v1.0.1
Published
An expo router navigation template
Downloads
8
Readme
This project demonstrates how Expo Router could be used to create a basic authentication flow.
⬇️ How to use this template
If you want to create your own initial project with this boilerplate template, use npm or yarn.
npm
npx create-expo-app your-app-name --template expo-router-template
yarn
yarn create expo-app your-app-name --template expo-router-template
📱 Preview
https://user-images.githubusercontent.com/18494040/233866169-89a9b6c7-be67-4459-9b9f-5b761137d25e.mov
🧭 Navigation Structure
app/
_layout.tsx # Stack
(auth)/
_layout.tsx # Stack
login.tsx
onboarding.tsx
register.tsx
main
_layout.tsx # Drawer
home/
_layout.tsx # Tabs
feed.tsx
notification.tsx
profile.tsx
search.tsx
📁 Project Structure
app
- The navigation structured with all the the screens on the app.context
- The context for the authentication flow that expose hooks to access the context withuseAuth
and handle the authentication/authorization routing withuseProtectedRoute
.
🚀 How to develop it
To get your hands dirty, follow these steps.
$ npm install
or$ yarn install
- This will install all the required dependencies.$ npm start
or$ yarn start
- This will start the app, select a platform once complete.