livelike_flutter_sdk 0.2.0 livelike_flutter_sdk: ^0.2.0 copied to clipboard
To use the services and features of LiveLike SDK
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:livelike_flutter_sdk_example/all_features_screen.dart';
import 'package:livelike_flutter_sdk_example/chat_only_screen.dart';
import 'package:livelike_flutter_sdk_example/home.dart';
import 'package:livelike_flutter_sdk_example/leaderboard_screen.dart';
import 'package:livelike_flutter_sdk_example/program_screen.dart';
import 'package:livelike_flutter_sdk_example/select_channel.dart';
import 'package:livelike_flutter_sdk_example/sponsor_screen.dart';
import 'package:livelike_flutter_sdk_example/timeline_screen.dart';
import 'package:livelike_flutter_sdk_example/widget_details_screen.dart';
import 'package:livelike_flutter_sdk_example/widget_json_theme_screen.dart';
import 'package:livelike_flutter_sdk_example/widget_list_screen.dart';
import 'package:livelike_flutter_sdk_example/widgets_only_screen.dart';
void main() async {
Get.isLogEnable = true;
WidgetsFlutterBinding.ensureInitialized();
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return GetMaterialApp(
title: "Test App",
theme: ThemeData(
primarySwatch: Colors.blue,
),
getPages: [
GetPage(name: Routes.home.toString(), page: () => HomeScreen()),
GetPage(name: Routes.chatOnly.toString(), page: () => ChatOnlyScreen()),
GetPage(
name: Routes.leaderBoard.toString(),
page: () => LeaderBoardScreen()),
GetPage(name: Routes.sponsor.toString(), page: () => SponsorScreen()),
GetPage(
name: Routes.widgetDetails.toString(), page: () => WidgetDetails()),
GetPage(
name: Routes.widgetList.toString(), page: () => WidgetListScreen()),
GetPage(
name: Routes.widgetDetails.toString(), page: () => WidgetDetails()),
GetPage(
name: Routes.widgetOnly.toString(),
page: () => WidgetsOnlyScreen()),
GetPage(
name: Routes.allfeatures.toString(),
page: () => AllFeaturesScreen()),
GetPage(
name: Routes.selectChannel.toString(), page: () => SelectChannel()),
GetPage(name: Routes.programs.toString(), page: () => ProgramScreen()),
GetPage(name: Routes.timeLine.toString(), page: () => TimeLineScreen()),
GetPage(name: Routes.jsonTheme.toString(), page: () => WidgetJsonThemeScreen()),
],
initialRoute: Routes.home.toString(),
);
}
}
enum Routes {
home,
selectChannel,
allfeatures,
chatOnly,
widgetOnly,
leaderBoard,
sponsor,
widgetDetails,
programs,
widgetList,
jsonTheme,
timeLine
}