sse_client 0.0.2

Server Sent Events client package. #

This package provides support for bi-directional communication through Server Sent Events and corresponding POST requests. It's platform-independent, and can be used on both the command-line and the browser.

Usage #

A simple usage example:

import 'package:sse_client/sse_client.dart';

main() {


0.0.1 #

  • Initial version

0.0.2 #

  • Many breaking changes

Use this package as a library

1. Depend on it

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

  sse_client: ^0.0.2

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:sse_client/sse_client.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 12, 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 suggestions

Format lib/html.dart.

Run dartfmt to format lib/html.dart.

Format lib/io.dart.

Run dartfmt to format lib/io.dart.

Format lib/src/_connect_api.dart.

Run dartfmt to format lib/src/_connect_api.dart.

Fix additional 5 files with analysis or formatting issues.

Additional issues in the following files:

  • lib/src/_connect_html.dart (Run dartfmt to format lib/src/_connect_html.dart.)
  • lib/src/_connect_io.dart (Run dartfmt to format lib/src/_connect_io.dart.)
  • lib/src/event_source_transformer.dart (Run dartfmt to format lib/src/event_source_transformer.dart.)
  • lib/src/sse_client.dart (Run dartfmt to format lib/src/sse_client.dart.)
  • lib/sse_client.dart (Run dartfmt to format lib/sse_client.dart.)

Maintenance suggestions

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.

Maintain an example.

None of the files in the package's example/ directory matches known example patterns.

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

For more information see the pub package layout conventions.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.6.0 <3.0.0
http ^0.12.0+2 0.12.0+4
stream_channel >=1.6.8 <3.0.0 2.0.0
Transitive dependencies
async 2.4.0
charcode 1.1.3
collection 1.14.12
http_parser 3.1.3
meta 1.1.8
path 1.6.4
source_span 1.6.0
string_scanner 1.0.5
term_glyph 1.1.0
typed_data 1.1.6
Dev dependencies
pedantic ^1.8.0 1.9.0
test ^1.6.0