Whatsapp Clone using Amplify DataStore in Flutter
About The Project
Built With
Getting Started
To get a local copy up and running follow these simple steps.
Prerequisites
- You should have Flutter installed in your system.
- AWS account is required to provision all the resources.
- AWS Amplify CLI should be installed and configured with AWS Account.
Installation
- Clone the repogit clone https://github.com/GeekyAnts/flutter_amplify_datastore_demo
- Install NPM packagesflutter pub get
- Run Amplify init to initialize Amplify project and app api to provision resourceamplify init amplify add api amplify add auth // Choose email and password authentication.
- Replace graphql schema in
amplify/backend/api/FlutterAmplifyApi/schema.graphql
file with below content.type ChatRoom @model @auth(rules: [{ allow: public }]) @key(name: “byUser”, fields: [“userID”]) { id: ID! otherUserId: String otherUserName: String userID: ID chatId: String untitledfield: String } type ChatData @model @auth(rules: [{ allow: public }]) { id: ID! message: String createdAt: AWSDateTime chatRoomId: String senderId: String } type User @model @auth(rules: [{ allow: public }]) { id: ID! username: String! email: String bio: String profileImage: String isVerified: Boolean createdAt: AWSDateTime chats: AWSJSON ChatRooms: [ChatRoom] @connection(keyName: “byUser”, fields: [“id”]) }
Contributing
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/flutter_amplify_datastore_demo
) - Commit your Changes (
git commit -m 'Add some flutter_amplify_datastore_demo'
) - Push to the Branch (
git push origin feature/flutter_amplify_datastore_demo
) - Open a Pull Request
Download WhatsApp clone app source code on GitHub
Provides the list of the opensource Flutter apps collection with GitHub repository.