This package provides support for bi-directional communication through Server Sent Events and corresponding POST requests.
- Fix an issue where the
SseClientwould not send a
doneevent when there was an error with the SSE connection.
Note that this is a breaking change but in actuality no one should be depending on this API.
- Add optional
keepAliveparameter to the
keepAliveis supplied, the connection will remain active for this period after a disconnect and can be reconnected transparently. If there is no reconnect within that period, the connection will be closed normally.
- Add retry logic.
Possible Breaking Change Error messages may now be delayed up to 5 seconds in the client.
- Use proper headers delimiter.
- Support Firefox.
- Fix an issue where messages could come out of order.
- Support the latest
- Require Dart SDK
- Update to
- No longer expose
SseConnection. This is simply handled by the underlying
- Fix a bug where resources of the
SseConnectionwere not properly closed.
- Internal cleanup.
- Initial commit.
Use this package as a library
1. Depend on it
Add this to your package's pubspec.yaml file:
dependencies: sse: ^3.1.2
2. Install it
You can install packages from the command line:
$ pub get
$ 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'; import 'package:sse/server/sse_handler.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]
We analyzed this package on Feb 17, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
- Dart: 2.7.1
- pana: 0.13.5
Maintain an example.
None of the files in the package's
example/ directory matches known example patterns.
Common filename patterns include
sse.dart. Packages with multiple examples should provide
For more information see the pub package layout conventions.
|Dart SDK||>=2.2.0 <3.0.0|