firebase_storage_image 0.4.0

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • 50

firebase_storage_image #

pub package

Flutter's ImageProvider for images in Firebase Cloud Storage.

Getting Started #

FirebaseStorageImage implements ImageProvider. So you can use this directly for Image, CircleAvatar, ImageIcon, and something like that.

Example #

import 'package:flutter/material.dart';
import 'package:firebase_storage_image/firebase_storage_image.dart';

class YourCircleAvatar extends StatelessWidget {
  @override
  Widget build(BuildContext context) => const CircleAvatar(
        backgroundImage: FirebaseStorageImage(
          'gs://project-12345.appspot.com/path/to/avatar_image.png',
        ),
      );
}

License #

MIT

Contribution #

I need your help improving this package with leaving Pull Requests and Issues!

[0.4.0] - 2019-05-30

  • Changed code for Flutter 1.6+ compatibility (#9)

[0.3.0] - 2019-05-30

  • Update dependencies (#7)

[0.2.1] - 2018-12-31

  • Make all the code formatted by Dart's linter

[0.2.0] - 2018-12-23

  • Breaking changes
    • Add a new option of constructor: firebaseApp
    • Change type of the first argument from Uri to String

[0.1.0] - 2018-12-23

  • Breaking changes
    • Make the FirebaseStorageImage‚Äôs default constructor const
    • Change default allocated size from 2MB to 1MB

[0.0.4] - 2018-12-23

  • Correcting pubspec.yaml

[0.0.3] - 2018-12-23

  • Added document to code.

[0.0.2] - 2018-12-23

  • Only correcting pubspec.yaml

[0.0.1] - 2018-12-23

  • Initial release, should be polished. I want your help with an issue!

example/example.dart

import 'package:flutter/material.dart';
import 'package:firebase_storage_image/firebase_storage_image.dart';

class YourImage extends StatelessWidget {
  @override
  Widget build(BuildContext context) => const Image(
        image: FirebaseStorageImage(
          'gs://project-12345.appspot.com/path/to/image.png',
        ),
      );
}

class YourCircleAvatar extends StatelessWidget {
  @override
  Widget build(BuildContext context) => const CircleAvatar(
        backgroundImage: FirebaseStorageImage(
          'gs://project-12345.appspot.com/path/to/avatar_image.png',
        ),
      );
}

class YourImageIcon extends StatelessWidget {
  @override
  Widget build(BuildContext context) => const ImageIcon(
        FirebaseStorageImage(
          'gs://project-12345.appspot.com/path/to/icon_image.png',
        ),
      );
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  firebase_storage_image: ^0.4.0

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter pub get

Alternatively, your editor might support pub get or flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:firebase_storage_image/firebase_storage_image.dart';
  
Version Uploaded Documentation Archive
0.4.0 May 31, 2019 Go to the documentation of firebase_storage_image 0.4.0 Download firebase_storage_image 0.4.0 archive
0.3.0 May 31, 2019 Go to the documentation of firebase_storage_image 0.3.0 Download firebase_storage_image 0.3.0 archive
0.2.1 Jan 1, 2019 Go to the documentation of firebase_storage_image 0.2.1 Download firebase_storage_image 0.2.1 archive
0.2.0 Dec 24, 2018 Go to the documentation of firebase_storage_image 0.2.0 Download firebase_storage_image 0.2.0 archive
0.1.0 Dec 23, 2018 Go to the documentation of firebase_storage_image 0.1.0 Download firebase_storage_image 0.1.0 archive
0.0.4 Dec 23, 2018 Go to the documentation of firebase_storage_image 0.0.4 Download firebase_storage_image 0.0.4 archive
0.0.3 Dec 23, 2018 Go to the documentation of firebase_storage_image 0.0.3 Download firebase_storage_image 0.0.3 archive
0.0.2 Dec 23, 2018 Go to the documentation of firebase_storage_image 0.0.2 Download firebase_storage_image 0.0.2 archive
0.0.1 Dec 23, 2018 Go to the documentation of firebase_storage_image 0.0.1 Download firebase_storage_image 0.0.1 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
73
Health:
Code health derived from static analysis. [more]
0
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
70
Overall:
Weighted score of the above. [more]
50
Learn more about scoring.

We analyzed this package on Jun 19, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.3.2
  • pana: 0.12.18
  • Flutter: 1.5.4-hotfix.2

Platforms

Detected platforms:

Error(s) prevent platform classification:

Fix dependencies in pubspec.yaml.

Analysis issues and suggestions

Fix dependencies in pubspec.yaml.

Running flutter pub upgrade failed with the following output:

ERR: The current Flutter SDK version is 1.5.4-hotfix.2.
 
 Because firebase_storage_image requires Flutter SDK version >=1.6.0, version solving failed.

Health suggestions

Format lib/firebase_storage_image.dart.

Run flutter format to format lib/firebase_storage_image.dart.

Maintenance issues and suggestions

Fix platform conflicts. (-20 points)

Error(s) prevent platform classification:

Fix dependencies in pubspec.yaml.

Make sure dartdoc successfully runs on your package's source files. (-10 points)

Dependencies were not resolved.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev.68.0 <3.0.0