lb_bitstream 1.0.0 lb_bitstream: ^1.0.0 copied to clipboard
Logbot bitstream client to be used for API requests to Logbot Graphite Bitstream APIs
// Copyright 2022 Logbot SRL. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'package:example/ui/apis/auto_complete_values_page.dart';
import 'package:example/ui/apis/autocomplete_tags_api_page.dart';
import 'package:example/ui/apis/index_api_page.dart';
import 'package:example/ui/apis/render_api_page.dart';
import 'package:example/ui/home_page.dart';
import 'package:example/ui/login_page.dart';
import 'package:flutter/material.dart';
import 'package:flutter_dotenv/flutter_dotenv.dart';
Future<void> main() async {
await dotenv.load(fileName: ".env");
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Logbot SDK - Bitstream Example',
themeMode: ThemeMode.light,
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: const LoginPage(),
initialRoute: '/login',
routes: {
'/home': (context) => const HomePage(),
'/login': (context) => const LoginPage(),
'/bitstream/index': (context) => const IndexApiPage(),
'/bitstream/render': (context) => const RenderApiPage(),
'/bitstream/autocomplete/tags': (context) =>
const AutoCompleteTagsPage(),
'/bitstream/autocomplete/values': (context) =>
const AutoCompleteValuesPage(),
},
);
}
}