{"id":15395077,"url":"https://github.com/goto-bus-stop/dart-event-source","last_synced_at":"2025-07-19T15:32:51.519Z","repository":{"id":56841769,"uuid":"152863273","full_name":"goto-bus-stop/dart-event-source","owner":"goto-bus-stop","description":"W3C EventSource client implementation for Dart","archived":false,"fork":false,"pushed_at":"2020-06-20T20:41:36.000Z","size":33,"stargazers_count":9,"open_issues_count":3,"forks_count":11,"subscribers_count":3,"default_branch":"default","last_synced_at":"2025-03-29T03:05:40.019Z","etag":null,"topics":["dart","event-source","event-source-client","flutter"],"latest_commit_sha":null,"homepage":null,"language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/goto-bus-stop.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-10-13T10:59:48.000Z","updated_at":"2023-05-17T13:22:37.000Z","dependencies_parsed_at":"2022-08-29T12:51:00.318Z","dependency_job_id":null,"html_url":"https://github.com/goto-bus-stop/dart-event-source","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goto-bus-stop%2Fdart-event-source","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goto-bus-stop%2Fdart-event-source/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goto-bus-stop%2Fdart-event-source/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goto-bus-stop%2Fdart-event-source/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/goto-bus-stop","download_url":"https://codeload.github.com/goto-bus-stop/dart-event-source/tar.gz/refs/heads/default","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249173061,"owners_count":21224481,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dart","event-source","event-source-client","flutter"],"created_at":"2024-10-01T15:25:38.314Z","updated_at":"2025-04-15T23:53:59.292Z","avatar_url":"https://github.com/goto-bus-stop.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# w3c_event_source\n\n[![pub package][0]][1]\n[![build status][2]][3]\n\n[0]: https://img.shields.io/pub/v/w3c_event_source.svg?style=flat-square\n[1]: https://pub.dartlang.org/packages/w3c_event_source\n[2]: https://img.shields.io/travis/com/goto-bus-stop/dart-event-source/default.svg?style=flat-square\n[3]: https://travis-ci.com/goto-bus-stop/dart-event-source\n\nW3C [EventSource][] client implementation for Dart / Flutter.\n\n\u003e This package depends on `dart:io`, so it is not usable on the Web.\n\u003e If you'd like to contribute a wrapper around [`dart:html`'s EventSource](https://api.dartlang.org/stable/2.0.0/dart-html/EventSource-class.html), feel free!\n\n## Install\n\nAdd to your `pubspec.yaml`:\n\n```yaml\ndependencies:\n  w3c_event_source: ^1.3.2\n```\n\n## Usage\n\n```dart\nimport 'dart:async';\nimport 'package:w3c_event_source/event_source.dart';\n\nfinal events = EventSource(Uri.parse('http://api.example.com/ssedemo.php'));\n\n// Listening on the `events` stream will open a connection.\nfinal subscription = events.events.listen((MessageEvent message) {\n  print('${message.name}: ${message.data}');\n});\n\nTimer(Duration(seconds: 30), () {\n  // Canceling the subscription closes the connection.\n  subscription.cancel();\n});\n```\n\n## License\n\n[MIT](./LICENSE)\n\n[EventSource]: https://developer.mozilla.org/en-US/docs/Web/API/EventSource\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoto-bus-stop%2Fdart-event-source","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoto-bus-stop%2Fdart-event-source","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoto-bus-stop%2Fdart-event-source/lists"}