Chunked Uploader

A plugin to upload files to server in chunks.

pub package

Usage

To use this plugin, add chunked_uploader as dependency in your pubspec.yaml file.

dependencies:
  flutter:
    sdk: flutter
  chunked_uploader: ^0.0.2+1

Example

ChunkedUploader chunkedUploader = ChunkedUploader(Dio(BaseOptions(
    baseUrl: 'https://example.com/api',
    headers: {'Authorization': 'Bearer'})));
try {
  Response response = await chunkedUploader.upload(
      filePath: '/path/to/file',
      maxChunkSize: 500000,
      path: '/file',
      onUploadProgress: (progress) => print(progress));
  print(response);
} on DioError catch (e) {
  print(e);
}

Libraries

chunked_uploader