flutter_file_downloader 1.1.0+1 copy "flutter_file_downloader: ^1.1.0+1" to clipboard
flutter_file_downloader: ^1.1.0+1 copied to clipboard

A simple flutter plugin that downloads any file type to downloads directory

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:flutter_file_downloader_example/multiple_downloads.dart';
import 'package:flutter_file_downloader_example/settings.dart';

import 'single_download.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({Key? key}) : super(key: key);

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

class _MyAppState extends State<MyApp> with SingleTickerProviderStateMixin {
  late final TabController tabController =
      TabController(length: 3, vsync: this, initialIndex: 1);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      locale: Locale('ar'),
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Flutter file downloader example'),
        ),
        body: TabBarView(
          controller: tabController,
          children: const [
            SettingsScreen(),
            SingleDownloadScreen(),
            MultipleDownloads(),
          ],
        ),
        bottomNavigationBar: TabBar(
          tabs: const [
            Tab(icon: Icon(Icons.settings), text: 'Settings'),
            Tab(icon: Icon(Icons.download_rounded), text: 'Single download'),
            Tab(icon: Icon(Icons.cloud_download), text: 'Bulk download'),
          ],
          controller: tabController,
          labelColor: Colors.blue,
          unselectedLabelColor: Colors.grey,
        ),
      ),
    );
  }
}
129
likes
0
pub points
97%
popularity

Publisher

verified publisherodeh-bros.com

A simple flutter plugin that downloads any file type to downloads directory

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on flutter_file_downloader