storage_manager 0.2.4 copy "storage_manager: ^0.2.4" to clipboard
storage_manager: ^0.2.4 copied to clipboard

FireStorage & DevicePersistor Manager facilitates quick implementation in your app

MIS Develop

Features #

Storage Manager for online (FireStorage) and offline (Shared Preferences) purposes

Getting started #

Add this import line

import 'package:storage_manager/storage_manager.dart';  

Usage #

Save (upload), get (download) and remove (delete) #

Upload an Object (image, string, json or bytes) to given path

  String url = await StorageProvider.i.save('collectionName/Image.png', image);  

Get images, text and data to device persistor

  var imageBytes = await StorageProvider.i.get('collectionName/Image.png');  

Remove files from storage or local path

  bool removed = await StorageProvider.i.remove('collectionName/Image.png');  

or from storage URL

  bool success = await StorageProvider.i.removeUrl('url');  

Integrated image picker feature #

   if(await StorageProvider.i.selectImages()){
        List<XFile> images =  StorageProvider.i.selectedAssets;
   }else{
        print('User cancelled selection');
   }

Upload selected images to given path

    /// You can use the selectedAssets from the previous step or select new ones with image_picker
    List<XFile> images = StorageProvider.i.selectedAssets;
    List<String> urls = await StorageProvider.i.save('collectionName', images);  
  String url = await StorageProvider.i.selectAndUpload();  

Additional information #

This package assumes complete Firebase configuration with Storage and permissions.

8
likes
0
pub points
63%
popularity

Publisher

verified publishermisdevelop.app

FireStorage & DevicePersistor Manager facilitates quick implementation in your app

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

firebase_storage, flutter, image_picker, shared_preferences

More

Packages that depend on storage_manager