Skip to content

Commit 49c59de

Browse files
committed
* readme update
* License
1 parent a7555ee commit 49c59de

File tree

5 files changed

+85
-1
lines changed

5 files changed

+85
-1
lines changed

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 PubNub
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

+64-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,64 @@
1-
# flutter-ref-app-simple-chat
1+
# PubNub Chat App
2+
3+
The Simple chat app demonstrates how to build a chat application using [PubNub Chat](https://www.pubnub.com/docs/chat/quickstart) and [PubNub Dart SDK](https://www.pubnub.com/docs/sdks/dart). Learn how to add private messaging and group messaging features in general chat application. Learn how to build features like send/receive messages, typing indicators, online members list. You can download the project to run on your local machine, and explore the code to see how we built it.
4+
5+
![Home](screenshot/home.png) | ![Profile](screenshot/profile.png) | ![Presence](screenshot/presence.png) |
6+
--- | ---- | ---- |
7+
8+
The application uses [PubNub](https://www.pubnub.com/) service with [Dart SDK](https://pub.dev/packages/pubnub).
9+
10+
## Prerequisites
11+
12+
- [Flutter](https://flutter.dev/docs/get-started/install)
13+
- [PubNub Account](#pubnub-account) (*Free*)
14+
15+
## PubNub Account
16+
17+
To run this application you must obtain publish and subscribe keys from your PubNub Account. If you don't already have an account, you can [create one for free](https://dashboard.pubnub.com/).
18+
19+
1. Sign in to your [PubNub Dashboard](https://dashboard.pubnub.com/).
20+
21+
1. Click **Create New App**.
22+
23+
1. Give your app a name, and select **Chat App** as the app type.
24+
25+
1. Select a region to store your user data (e.g. *Portland*).
26+
27+
1. Click **Create**.
28+
29+
1. Click your new app to open its settings, then click its keyset.
30+
31+
1. Locate the *Publish* and *Subscribe* keys. Include these keys in this project's `.env` file.
32+
33+
## Running the project
34+
35+
1. Clone the GitHub repository.
36+
37+
```bash
38+
git clone https://github.com/pubnub/flutter-ref-app-simple-chat.git
39+
```
40+
41+
1. Add `.env` file with keyset values as described in `.env.sample`.
42+
43+
```dart
44+
PUBNUB_SUBSCRIBE_KEY="<Enter Your PubNub Publish Key Here>"
45+
PUBNUB_PUBLISH_KEY="<Enter Your PubNub Subscribe Key Here>"
46+
```
47+
48+
1. Install the dependencies.
49+
50+
```bash
51+
cd flutter-ref-app-simple-chat
52+
flutter pub get
53+
```
54+
55+
1. Start an simulator or connect your device and run application with selected device.
56+
57+
```bash
58+
flutter run
59+
```
60+
61+
## Further Information
62+
63+
Visit the [PubNub Dart SDK Docs](https://www.pubnub.com/docs/sdks/dart) page for more information about how to use PubNub Dart SDK.
64+
Please refer [Flutter Install](https://flutter.dev/docs/get-started/install) page for flutter framework and simulator setup.

screenshot/home.png

535 KB
Loading

screenshot/presence.png

308 KB
Loading

screenshot/profile.png

204 KB
Loading

0 commit comments

Comments
 (0)