arch_foundations 0.3.1

arch_foundations #

Flutter architecture foundations I use in my apps. Work in progress.

[0.3.1]

  • Added isSuccess to Resource.

[0.3.0]

  • Changed stack trace type to StackTrace in ErrorBundle.

[0.2.0]

  • Replaced message with error in Resource. It's now an ErrorBundle type which also includes exception and stack trace information.

[0.1.3]

  • Renamed ApiResponse.withException to withError and changed param type to Object from Exception

[0.1.2]

  • Made ApiResponse independent of response types

[0.1.1]

  • Some patching

[0.1.0]

  • Real initial release

[0.0.1]

  • Initial release

example/main.dart

void main() {
  // TODO
}

Use this package as a library

1. Depend on it

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


dependencies:
  arch_foundations: ^0.3.1

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support 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:arch_foundations/error_bundle.dart';
import 'package:arch_foundations/api_response.dart';
import 'package:arch_foundations/arch/bloc.dart';
import 'package:arch_foundations/arch/bloc_provider.dart';
import 'package:arch_foundations/arch/bloc_user_state.dart';
import 'package:arch_foundations/arch/dependant_stream.dart';
import 'package:arch_foundations/arch/network_bound_resource.dart';
import 'package:arch_foundations/arch/network_bound_resource_client.dart';
import 'package:arch_foundations/mixin/snackbarer.dart';
import 'package:arch_foundations/mixin/snackbarer_mixin.dart';
import 'package:arch_foundations/resource.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
4
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
90
Overall:
Weighted score of the above. [more]
50
Learn more about scoring.

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

  • Dart: 2.7.1
  • pana: 0.13.5
  • Flutter: 1.12.13+hotfix.7

Health suggestions

Fix lib/arch/bloc_provider.dart. (-0.50 points)

Analysis of lib/arch/bloc_provider.dart reported 1 hint:

line 19 col 37: 'ancestorWidgetOfExactType' is deprecated and shouldn't be used. Use findAncestorWidgetOfExactType instead. This feature was deprecated after v1.12.1..

Maintenance issues and suggestions

Support latest dependencies. (-10 points)

The version constraint in pubspec.yaml does not support the latest published versions for 1 dependency (rxdart).

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
bloc_event_gen ^0.1.3 0.1.3
flutter 0.0.0
http ^0.12.0 0.12.0+4
rxdart ^0.22.0 0.22.6 0.23.1
Transitive dependencies
async 2.4.0
charcode 1.1.3
collection 1.14.11 1.14.12
http_parser 3.1.3
meta 1.1.8
path 1.6.4
pedantic 1.9.0
sky_engine 0.0.99
source_span 1.6.0
string_scanner 1.0.5
term_glyph 1.1.0
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
bloc_event_generator ^0.1.3
flutter_test
mockito ^4.1.0
test any