angel_firestore 0.1.3

  • Readme
  • Changelog
  • Example
  • Installing
  • new63

angel_firestore #

Pub

Admin Firebase firestore service for the angel framework

[0.1.3] #

  • Linting
  • Upgrade dartbase_admin dep

[0.1.2] #

  • Linting

[0.1.1] #

  • Linting

[0.1.0] #

  • Initial release

example/example.dart

import 'package:angel_firestore/angel_firestore.dart';
import 'package:angel_framework/angel_framework.dart';
import 'package:dartbase_admin/dartbase_admin.dart';

void main() async {
  var app = Angel();
  var firebase = await Firebase.initialize('your-firebase-project-id',
      await ServiceAccount.fromFile('service-account.json'));
  var firestore = Firestore(firebase: firebase);
  var collection = firestore.collection('test');

  var service = app.use('/api/users', FirestoreClientService(collection));

  service.afterCreated.listen((event) {
    print('New user: ${event.result}');
  });
}

Use this package as a library

1. Depend on it

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


dependencies:
  angel_firestore: ^0.1.3

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:angel_firestore/angel_firestore.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
26
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100
Overall:
Weighted score of the above. [more]
63
Learn more about scoring.

We analyzed this package on Jul 9, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.8.4
  • pana: 0.13.14

Analysis suggestions

Package not compatible with runtime flutter-web on web

Because:

  • package:angel_firestore/angel_firestore.dart that imports:
  • package:angel_firestore/firestore_service.dart that imports:
  • package:dartbase_admin/dartbase_admin.dart that imports:
  • package:dartbase_admin/storage/firebase_storage.dart that imports:
  • package:googleapis_auth/auth_io.dart that imports:
  • package:googleapis_auth/src/oauth2_flows/metadata_server.dart that imports:
  • dart:io

Package not compatible with runtime js

Because:

  • package:angel_firestore/angel_firestore.dart that imports:
  • package:angel_firestore/firestore_service.dart that imports:
  • package:dartbase_admin/dartbase_admin.dart that imports:
  • package:dartbase_admin/storage/firebase_storage.dart that imports:
  • package:googleapis_auth/auth_io.dart that imports:
  • package:googleapis_auth/src/oauth2_flows/metadata_server.dart that imports:
  • dart:io

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
angel_framework ^2.1.1 2.1.1
dartbase_admin ^0.1.3 0.1.3
http ^0.12.1 0.12.1
Transitive dependencies
_discoveryapis_commons 0.2.0
angel_http_exception 1.1.0
angel_model 1.0.3
angel_route 3.1.0+1
args 1.6.0
asn1lib 0.6.5
async 2.4.2
built_collection 4.3.2
built_value 7.1.0
charcode 1.1.3
clock 1.0.1
code_buffer 1.0.1
collection 1.14.13 1.15.0-nullsafety
combinator 1.1.0
convert 2.1.1
crypto 2.1.5
crypto_keys 0.1.3
dart2_constant 1.0.2+dart2
file 5.2.1
fixnum 0.10.11
gcloud 0.7.3
googleapis 0.55.0
googleapis_auth 0.2.12
grpc 2.2.0
http2 1.0.0
http_parser 3.1.4
http_server 0.9.8+3
intl 0.16.1
jose 0.1.2+1 0.2.1+1
json_annotation 3.0.1
logging 0.11.4
matcher 0.12.8
merge_map 1.0.2
meta 1.2.2 1.3.0-nullsafety
mime 0.9.6+3
mock_request 1.0.7
openid_client 0.2.5
path 1.7.0
pointycastle 1.0.2
protobuf 1.0.1
quiver 2.1.3
quiver_hashcode 2.0.0
recase 2.0.1 3.0.0
source_span 1.7.0
stack_trace 1.9.5
string_scanner 1.0.5
term_glyph 1.1.0
tuple 1.0.3
typed_data 1.2.0 1.3.0-nullsafety
uuid 2.2.0
x509 0.1.2+1
Dev dependencies
angel_container ^1.1.0 1.1.0
dotenv ^2.0.0
json_god >=2.0.0-beta <3.0.0
pedantic ^1.9.0 1.9.2
test ^1.15.1