easychat 0.0.13 copy "easychat: ^0.0.13" to clipboard
easychat: ^0.0.13 copied to clipboard

Full featured and complete chat package for Flutter and Firebase

example/lib/main.dart

// import 'package:example/firebase_options.dart';
import 'package:example/screens/home/home.screen.dart';
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/material.dart';
import 'package:easy_locale/easy_locale.dart';
import 'package:easychat/easychat.dart';

void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  lo.init();
  await Firebase.initializeApp(
      // options: DefaultFirebaseOptions.currentPlatform,
      );
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({super.key});

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
    debugPrint('--> MayApp::initState() begins;');
    ChatService.instance.init();
  }

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      home: HomeScreen(),
    );
  }
}