Search packages, repositories and app categories

firebase_chat cover
Package detailsv0.0.6+1

firebase_chat

Fully functional package for Cloud Firestore that makes easier to implement chat in your application

30-day downloads
16
Likes
32
Pub points
50

Install package

flutter pub add firebase_chat

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

A fully functional Flutter package that simplifies implementing chat functionality using Cloud Firestore. It provides ready-to-use components and utilities to manage real-time messaging, message persistence, and user presence with minimal setup. Designed for seamless integration with Firebase, it handles common chat patterns such as message sending, receiving, typing indicators, and read receipts. Ideal for developers aiming to quickly add robust chat features to their apps without writing boilerplate code.

Use cases

  • Real-time messaging apps
  • Customer support chat interfaces
  • Team collaboration tools
  • In-app messaging systems
  • Social networking applications

Key features

  • Pre-built chat UI components
  • Real-time message synchronization
  • Typing indicators and read receipts
  • Message persistence with Cloud Firestore
  • Easy integration with Firebase authentication

Suitable for

  • Developers building chat-enabled apps
  • Startups needing rapid chat implementation
  • Apps requiring real-time communication
  • Firebase-based projects
  • Prototyping chat features

Considerations

  • Requires Firebase Cloud Firestore setup
  • Limited customization without modifying source code
  • Depends on Firebase authentication
  • Not optimized for large-scale group chats
  • No built-in media upload support

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

Firebase Chat🔥💬

⛏️ Getting started

To get started with Firebase, please see the documentation available at https://firebase.flutter.dev/docs/overview

Add Firebase Chat to your project by following the instructions on the install page and start using it:

import 'package:firebase_chat/firebase_chat.dart';

📱 Example

Extend your StatefulWidget
class ChatPage extends BaseChat {
  ChatPage({
    @required ChatEntity entity,
  }) : super(entity);

  @override
  _ChatPageState createState() => _ChatPageState();
}

class _ChatPageState extends BaseChatState<ChatPage> {
...
Override Methods and Properties

You can checkout example file

Widget inputBuilder(BuildContext context, ChatInputState state);
Future editAndUpload(Uint8List data);
Future getImage();

Widget get emptyWidget;
Widget get errorWidget;
Widget get loadingWidget;
Color  get primaryColor;
Color  get secondaryColor;

Models 📦

Peer User 👨
Fields
  • id - user Id
  • image - user image url
  • name - user display name
Constructors
  • PeerUser({this.id, this.image, this.name})
  • PeerUser.fromSnapshot(DocumentSnapshot snap)
Chat Entity 📩
Fields
  • mainUser - logged in user
  • peers - Map of users <user ID, PeerUser>
  • lastMessage - last sent message
  • title - name of the chat (You can name group chats, can be nullable)

License ⚖️

Issues and feedback 💭

If you have any suggestion for including a feature or if something doesn't work, feel free to open a Github issue for us to have a discussion on it.

Categories

Dependencies

Dependency list 10 items

Source repository

Projects using this package

No data available yet.