telkom_file_downloader 0.0.2
telkom_file_downloader: ^0.0.2 copied to clipboard
A demonastration on how to use telkom_file_downloader plugin with lots of love from the Telkom team.
example/lib/main.dart
import 'package:flutter/material.dart';
import 'package:telkom_file_downloader/flutter_downloader.dart';
import 'home_page.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
await TelkomDownloader.initialize(debug: true, ignoreSsl: true);
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
static const _title = 'Telkom file downloader';
@override
Widget build(BuildContext context) {
final platform = Theme.of(context).platform;
return MaterialApp(
title: _title,
theme: ThemeData.light(),
darkTheme: ThemeData.dark(),
home: MyHomePage(
title: _title,
platform: platform,
),
);
}
}