collection_diff 1.0.3

  • Readme
  • Changelog
  • Installing
  • 53

collection_diff #

pub package Coverage Status

A flutter project that compares two collections and produces a list of deltas between then. This is useful when working with flutter's AnimatedList widgets, or any other time you want to respond to list changes without having to rebuild your entire view.

By default, the diffs run synchronously, which hurts performance if you run them in the main thread.
See the [collection_diff_isolate] package for running the diff operations in the background.

[1.0.3] - Improving tests #

[1.0.2] - Updated badge #

[1.0.0] - Changed API surface - refactored DiffEquality #

[0.4.4] - Initial release #

Use this package as a library

1. Depend on it

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


dependencies:
  collection_diff: ^1.0.3

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

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

  • Dart: 2.8.4
  • pana: 0.13.14
  • Flutter: 1.17.5

Analysis suggestions

Package not compatible with SDK dart

Because:

  • collection_diff that is a package requiring null.

Maintenance issues and suggestions

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

exitCode: 255 stdout: Documenting collection_diff... Initialized dartdoc with 95 libraries in 35.0 seconds Generating docs for library collection_diff from package:collection_diff/collection_diff.dart... Generating docs for library diff_algorithm from package:collection_diff/diff_algorithm.dart... Generating docs for library diff_equality from package:collection_diff/diff_equality.dart... Generating docs for library diff_extensions from package:collection_diff/diff_extensions.dart... Generating docs for library diff_model from package:collection_diff/diff_model.dart... Generating docs for library list_diff from package:collection_diff/map_diff.dart... Generating docs for library list_diff from package:collection_diff/list_diff.dart... Generating docs for library list_diff_model from package:collection_diff/list_diff_model.dart... Generating docs for library map_diff from package:collection_diff/algorithms/map_diff.dart... Generating docs for library map_diff_model from package:collection_diff/map_diff_model.dart... Generating docs for library myers from package:collection_diff/algorithms/myers.dart... Generating docs for library path_node from package:collection_diff/algorithms/path_node.dart... Generating docs for library set_diff from package:collection_diff/algorithms/set_diff.dart... Generating docs for library set_diff from package:collection_diff/set_diff.dart... Generating docs for library set_diff_model from package:collection_diff/set_diff_model.dart... Generating docs for library utils from package:collection_diff/algorithms/utils.dart... Generating docs for library wagner_fischer from package:collection_diff/algorithms/wagner_fischer.dart... Validating docs... Documented 17 public libraries in 9.2 seconds stderr: warning: unresolved doc reference [collection_diff_isolate], from package-collection_diff: file:///tmp/pub-dartlang-dartdocOCWKAM/pkg warning: collection_diff has no library level documentation comments, from collection_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/collection_diff.dart:1:9) warning: ambiguous doc reference [equals] => 'diff_equality.EqualityFromDiffable.equals', 'diff_equality.EqualityFromDiffable.equals', from diff_equality.EqualityFromDiffable.hash: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/diff_equality.dart:260:7) warning: ambiguous doc reference [equals] => 'diff_equality.EqualityFromDiffable.equals', 'diff_equality.EqualityFromDiffable.equals', from diff_equality.EqualityFromDiffable.isValidKey: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/diff_equality.dart:263:8) warning: Comment reference resolution inside extension methods is not yet implemented, from diff_extensions.StreamOfListDiffsExtensions.replacements: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/diff_extensions.dart:61:19) warning: unresolved doc reference [T], from diff_extensions.StreamOfListDiffsExtensions.replacements: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/diff_extensions.dart:61:19) warning: list_diff has no library level documentation comments, from list_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/map_diff.dart:1:9) warning: list_diff has no library level documentation comments, from list_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/list_diff.dart:1:9) error: failed to write file at: list_diff/list_diff-library.html for symbol list_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/list_diff.dart:1:9) conflicting with file already generated by list_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/map_diff.dart:1:9) Dartdoc generates a path and filename to write to for each symbol. list_diff conflicts with another symbol in the generated path, and therefore can not be written out. Changing the name, library name, or class name (if appropriate) of one of the conflicting items can resolve the conflict. Alternatively, use the @nodoc tag in one symbol's documentation comments to hide it. warning: set_diff has no library level documentation comments, from set_diff: (file:///tmp/pub-dartlang-dartdocOCWKAM/pkg/lib/set_diff.dart:1:9) found 9 warnings and 1 error Unhandled exception: dartdoc encountered 1 errors while processing. #0 Dartdoc.generateDocs (package:dartdoc/dartdoc.dart:225:9)

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and collection_diff.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.7.0 <3.0.0
collection ^1.14.11 1.14.12 1.14.13
flutter 0.0.0
uuid ^2.0.4 2.2.0
Transitive dependencies
charcode 1.1.3
convert 2.1.1
crypto 2.1.5
meta 1.1.8 1.2.2
sky_engine 0.0.99
typed_data 1.1.6 1.2.0
vector_math 2.0.8 2.1.0-nullsafety
Dev dependencies
coveralls <5.7.0
flutter_test