Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mmvergara/react-firebase-auth-template

React Firebase Auth template with Protected Routes 🔥
https://github.com/mmvergara/react-firebase-auth-template

boilerplate boilerplate-template firebase react react-router-dom template

Last synced: 29 days ago
JSON representation

React Firebase Auth template with Protected Routes 🔥

Awesome Lists containing this project

README

        


React Firebase Auth with Protected Routes

[**`🌐 App Demo`**](https://react-firebase-auth-templ-mmvergaras-projects.vercel.app/)



## Features

- 🚀 Protected Routes
- 🚀 Firebase User Object in Global Context via `useUser`
- 🚀 User Authentication
- 🚀 Routing

It's also blazingly fast 🔥 No really, [try it out for yourself.](https://react-firebase-auth-templ-mmvergaras-projects.vercel.app/)

[We also have a similar template for SUPABASE💚🍀](https://github.com/mmvergara/react-supabase-auth-template)
## Getting Started

1. Clone the repository
2. Install dependencies: `npm install`
3. Go to `./config.ts` and add your Firebase configuration
4. Run the app: `npm run dev`

## What you need to know

- `/router/index.tsx` is where you declare and manage your routes
- `/context/AuthContext.tsx` is where you can find the `useUser` hook
- This hook gives you access to the `user` object from Firebase Auth globally
- `/Providers.tsx` is where you can add more `providers` or `wrappers`