Skip to content

Instantly share code, notes, and snippets.

@adityagokula2210
Created November 12, 2024 11:20
Show Gist options
  • Select an option

  • Save adityagokula2210/d91c631c1df174ca20bb133b4a820435 to your computer and use it in GitHub Desktop.

Select an option

Save adityagokula2210/d91c631c1df174ca20bb133b4a820435 to your computer and use it in GitHub Desktop.
import 'package:cometchat_calls_uikit/cometchat_calls_uikit.dart';
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:voip_flutter/shared_preferences.dart';
import 'login_screen.dart';
Future<void> main() async {
WidgetsFlutterBinding.ensureInitialized();
runApp(const MyApp());
}
class MyApp extends StatefulWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return GetMaterialApp(
title: 'Flutter Demo',
debugShowCheckedModeBanner: false,
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
useMaterial3: true,
),
home: const Text('Flutter Demo Home Page'),
);
}
@override
State<StatefulWidget> createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
@override
void initState() {
initServices();
super.initState();
}
initServices() async {
SharedPreferencesClass.init();
}
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Push Notifications Sample App',
debugShowCheckedModeBanner: false,
theme: ThemeData(),
home: LoginScreen(
key: CallNavigationContext.navigatorKey,
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment