internet_file 1.2.0 copy "internet_file: ^1.2.0" to clipboard
internet_file: ^1.2.0 copied to clipboard

A internet file getter (also optional downloader) that works in all platforms

example/lib/internet_file_example.dart

import 'package:internet_file/internet_file.dart';
import 'package:internet_file/storage_io.dart';

void main() async {
  final storageIO = InternetFileStorageIO();

  await InternetFile.get(
    'http://www.africau.edu/images/default/sample.pdf',
    storage: storageIO,
    storageAdditional: storageIO.additional(
      filename: 'ui_icons.ttf',
      location: '',
    ),
    force: true,
    progress: (receivedLength, contentLength) {
      final percentage = receivedLength / contentLength * 100;
      print(
          'download progress: $receivedLength of $contentLength ($percentage%)');
    },
  );
}
107
likes
120
pub points
98%
popularity

Publisher

verified publisherserge.software

A internet file getter (also optional downloader) that works in all platforms

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

http, path, universal_file

More

Packages that depend on internet_file