libaqueous 0.0.16

libaqueous #

A Matrix SDK in Dart!

Currently it targets Flutter, web and Dart VM platforms.

Usage #

  1. Set up store
final store = SembastStore();
  1. Construct and load client
final client = Client(homeserver, username, token, store);
await client.loadFromStore();
  1. Register handler
EventHandler.eventBus.on<RoomNewEvent>().listen((e) {
  1. Sync

Features and Bugs #

Please file feature requests and bugs at the issue tracker.

1.0.0 #

  • Initial version, created by Stagehand

Use this package as a library

1. Depend on it

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

  libaqueous: ^0.0.16

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

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

  • Dart: 2.7.1
  • pana: 0.13.5

Health issues and suggestions

Document public APIs. (-0.51 points)

772 out of 785 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Fix lib/src/client/default_room.dart. (-1.99 points)

Analysis of lib/src/client/default_room.dart reported 4 hints:

line 85 col 76: Use ; instead of {} for empty constructor bodies.

line 87 col 47: Use ; instead of {} for empty constructor bodies.

line 151 col 10: The value of the local variable 'limited' isn't used.

line 314 col 20: Don't explicitly initialize variables to null.

Fix lib/src/client/default_client.dart. (-1.49 points)

Analysis of lib/src/client/default_client.dart reported 3 hints:

line 131 col 18: The value of the local variable 'e' isn't used.

line 198 col 7: Future results in async function bodies must be awaited or marked unawaited using package:pedantic.

line 212 col 13: The value of the local variable 'roomSync' isn't used.

Fix lib/src/client/default_user.dart. (-1 points)

Analysis of lib/src/client/default_user.dart reported 2 hints:

line 12 col 76: Use ; instead of {} for empty constructor bodies.

line 14 col 47: Use ; instead of {} for empty constructor bodies.

Fix additional 23 files with analysis or formatting issues. (-5 points)

Additional issues in the following files:

  • lib/src/rest/events/model/event.g.dart (2 hints)
  • lib/src/rest/events/model/room_message_event.g.dart (2 hints)
  • lib/src/rest/events/model/room_avatar_event.g.dart (1 hint)
  • lib/src/rest/events/model/room_canonical_alias_event.g.dart (1 hint)
  • lib/src/rest/events/model/room_image_event.g.dart (1 hint)
  • lib/src/rest/events/model/room_member_event.g.dart (1 hint)
  • lib/src/rest/events/model/room_name_event.g.dart (1 hint)
  • lib/src/rest/events/model/room_topic_event.g.dart (1 hint)
  • lib/src/rest/config/config.dart (Run dartfmt to format lib/src/rest/config/config.dart.)
  • lib/src/rest/events/model/event.dart (Run dartfmt to format lib/src/rest/events/model/event.dart.)
  • lib/src/rest/events/model/room_avatar_event.dart (Run dartfmt to format lib/src/rest/events/model/room_avatar_event.dart.)
  • lib/src/rest/events/model/room_message_event.dart (Run dartfmt to format lib/src/rest/events/model/room_message_event.dart.)
  • lib/src/rest/events/model/room_name_event.dart (Run dartfmt to format lib/src/rest/events/model/room_name_event.dart.)
  • lib/src/rest/events/model/room_topic_event.dart (Run dartfmt to format lib/src/rest/events/model/room_topic_event.dart.)
  • lib/src/rest/room/model/power_levels.g.dart (Run dartfmt to format lib/src/rest/room/model/power_levels.g.dart.)
  • lib/src/rest/room/model/receipt_data.dart (Run dartfmt to format lib/src/rest/room/model/receipt_data.dart.)
  • lib/src/rest/room/model/room_id.g.dart (Run dartfmt to format lib/src/rest/room/model/room_id.g.dart.)
  • lib/src/rest/room/model/room_members.g.dart (Run dartfmt to format lib/src/rest/room/model/room_members.g.dart.)
  • lib/src/rest/sync/model/account_data_element.dart (Run dartfmt to format lib/src/rest/sync/model/account_data_element.dart.)
  • lib/src/rest/sync/model/room_sync_response.g.dart (Run dartfmt to format lib/src/rest/sync/model/room_sync_response.g.dart.)
  • lib/src/rest/sync/model/user_account_data.dart (Run dartfmt to format lib/src/rest/sync/model/user_account_data.dart.)
  • lib/src/rest/sync/model/user_account_data_direct_message.g.dart (Run dartfmt to format lib/src/rest/sync/model/user_account_data_direct_message.g.dart.)
  • lib/src/rest/sync/sync.dart (Run dartfmt to format lib/src/rest/sync/sync.dart.)

Maintenance issues and suggestions

Support latest dependencies. (-30 points)

The version constraint in pubspec.yaml does not support the latest published versions for 3 dependencies (chopper, json_annotation, rxdart).

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
chopper ^2.3.0 2.5.3 3.0.1+1
json_annotation ^2.0.0 2.4.0 3.0.1
rxdart ^0.21.0 0.21.0 0.23.1
Transitive dependencies
async 2.4.0
charcode 1.1.3
collection 1.14.12
http 0.12.0+4
http_parser 3.1.3
logging 0.11.4
meta 1.1.8
path 1.6.4
pedantic 1.9.0
source_span 1.6.0
string_scanner 1.0.5
term_glyph 1.1.0
typed_data 1.1.6
Dev dependencies
build_runner ^1.1.3
chopper_generator ^2.3.0
json_serializable ^2.0.1
test ^1.0.0