media_saver 1.0.2

Flutter Android iOS

Quick and Simple save media file for Android and IOS,for android its Implements native permission ,For iOS you need setting info.plist with 'Privacy - Photo Library Additions Usage Description',Suppor

media_saver #

Pub

Quick and Simple save media file for Android and IOS

Features #

  • Implements native permission (Android)
  • Save image to Pictures for Android and IOS
  • Support save jpg/png/gif image
  • Support set image name, set image dir, set image suffix

Installation #

Add it to your pubspec.yaml file

dependencies:
   media_saver: <PLUGIN_VERSION>

Install it

pub get

Import it

import 'package:media_saver/media_saver.dart';

For iOS you need setting info.plist with

  Privacy - Photo Library Additions Usage Description

Usage #

    var response = await Dio().get(
      'https://flutter.dev/assets/flutter-lockup-c13da9c9303e26b8d5fc208d2a1fa20c1ef47eb021ecadf27046dea04c0cebf6.png',
      options: Options(responseType: ResponseType.bytes),
    );

    String path = await MediaSaver.saveImage(
      Uint8List.fromList(response.data),
      imageType: ImageType.PNG,
      fileName: 'saveFileName',
      directory: 'demo',
    );

License #

MIT @yk3372 @wsh794972562

4
likes
90
pub points
31%
popularity

Quick and Simple save media file for Android and IOS,for android its Implements native permission ,For iOS you need setting info.plist with 'Privacy - Photo Library Additions Usage Description',Support save jpg/png/gif image,Support set image name, set image dir, set image suffix

Repository (GitHub)
View/report issues

Documentation

API reference

Uploader

shuanghong.pianpian@gmail.com

License

MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on media_saver