Skip to content

Implement a small demo real-time chat app using the Realtime Database of Firebase.

Notifications You must be signed in to change notification settings

nguyenquanghuy15091995/nqh-chat-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NQH Chat App

========================================================

Install the npm package in project:

npm install

Run project:

npm start


Set Environment and Database

Step 1:

Create .env file at root project. In .env file you will create firebase config variable (Get on firebase project).

REACT_APP_FIREBASE_API_KEY=.....
REACT_APP_FIREBASE_AUTH_DOMAIN=.....
REACT_APP_FIREBASE_PROJECT_ID=.....
REACT_APP_FIREBASE_DATABASE_URL=.....
REACT_APP_FIREBASE_STORAGE_BUCKET=.....

Notes: In React project the environment variable name must start with "REACT_APP_"

Step 2:

Create firebase real-time database on https://firebase.google.com/ (Follow the Firebase document)

Database structure:

+<--Project-name-databse-->
|
+--admins // the element of admin list can create room
|  |
|  +--<--key-object-->
|      |
|      +--email: <--email-->
|      |
|      +--id: <--object-id-->
|
+--totalRoom: 0

About

Implement a small demo real-time chat app using the Realtime Database of Firebase.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published