Skip to content

Commit f72b846

Browse files
committed
demo(firebase): move to firebase demo directory
1 parent 87b7ee8 commit f72b846

24 files changed

+16
-13
lines changed

README.md

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@
88

99
# vue-advanced-chat
1010

11-
![Demo Image](demo/src/assets/web_mobile.png)
11+
![Demo Image](demo/firebase/src/assets/web_mobile.png)
1212

1313
## Sponsors
1414

1515
<div align="center">
16-
<a target="_blank" href="https://chatkitty.com">
17-
<img alt="ChatKitty sponsor" src="demo/src/assets/sponsors/chatkitty.png" width="220">
16+
<a target="_blank" href="https://chatkitty.com/docs">
17+
<img alt="ChatKitty sponsor" src="demo/firebase/src/assets/sponsors/chatkitty.png" width="220">
1818
</a>
19-
<div>Easy to use <a target="_blank" href="https://chatkitty.com">chat API/Server</a> with scalable infrastructure</div>
19+
<div>Easy to use <a target="_blank" href="https://chatkitty.com/docs">Chat API</a> with scalable infrastructure</div>
2020
</div>
2121

2222
## Features
@@ -72,6 +72,7 @@ You will get a fully working chat application for web and mobile:
7272
- [Props data structure](#props-data-structure)
7373
- [Events API](#events-api)
7474
- [Named Slots](#named-slots)
75+
- [Using with ChatKitty](#using-with-chatkitty)
7576
- [Using with Firestore](#using-with-firestore)
7677

7778
<br>
@@ -846,23 +847,25 @@ Example:
846847

847848
<br>
848849

850+
## Using with ChatKitty
851+
849852
## Using with Firestore
850853

851854
### Source code
852855

853-
You can find the source code to implement a full featured chat app using Firebase/Firestore inside the `demo` folder.
856+
You can find the source code to implement a full-featured chat app using Firebase/Firestore inside the `demo/firebase` folder.
854857
<br>
855858
To test it using your own Firebase project:
856859

857860
- Setup Cloud Firestore (to store users and rooms) and Realtime Database (to store users online status)
858861
- Clone this repository: `git clone https://github.com/advanced-chat/vue-advanced-chat.git`
859-
- Inside `demo/src/database/index.js` file, replace the line `const config = ...` by your own Firebase config
860-
- Go inside `demo` folder and run `npm run serve`
862+
- Inside `demo/firebase/src/database/index.js` file, replace the line `const config = ...` by your own Firebase config
863+
- Go inside `demo/firebase` folder and run `npm run serve`
861864

862865
### Data structure
863866

864-
If you decide to use the same code as in the `demo` folder to create your chat app, you need to have a specific Firestore data structure.<br>
865-
To help you get started, I added in `demo/src/App.vue` a method `addData` to initialize some data on your Firestore database.
867+
If you decide to use the same code as in the `demo/firebase` folder to create your chat app, you need to have a specific Firestore data structure.<br>
868+
To help you get started, I added in `demo/firebase/src/App.vue` a method `addData` to initialize some data on your Firestore database.
866869

867870
#### Users collection
868871

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

demo/index.html renamed to demo/firebase/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<meta charset="utf-8">
55
<meta http-equiv="X-UA-Compatible" content="IE=edge">
66
<meta name="viewport" content="width=device-width,initial-scale=1.0">
7-
<link rel="icon" href="/favicon.ico">
7+
<link rel="icon" href="/demo/firebase/favicon.ico">
88
<title>vue-advanced-chat</title>
99
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400,500,700" rel="stylesheet">
1010
</head>

demo/package.json renamed to demo/firebase/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"s": "npm run dev",
1212
"lint": "eslint --ext .js,.vue --ignore-path .gitignore --fix src",
1313
"reset": "rm -rf node_modules && rm -rf package-lock.json && npm i",
14-
"reset-all": "npm run reset && cd .. && npm run reset",
14+
"reset-all": "npm run reset && cd ../.. && npm run reset",
1515
"gpages": "sh deploy.sh",
1616
"latest": "npm i https://github.com/advanced-chat/vue-advanced-chat/tarball/master"
1717
},

demo/src/App.vue renamed to demo/firebase/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
import * as firestoreService from '@/database/firestore'
5959
import * as storageService from '@/database/storage'
6060
61-
import ChatContainer from './ChatContainer'
61+
import ChatContainer from './ChatContainer.vue'
6262
6363
export default {
6464
components: {

0 commit comments

Comments
 (0)