mercure_client 1.0.0 copy "mercure_client: ^1.0.0" to clipboard
mercure_client: ^1.0.0 copied to clipboard

outdated

Provide a quick way to publish and consume messages on Mercure

The features #

Provide a quick way to consume messages on Mercure.

Consuming messages #

import 'package:mercure_client/mercure_client.dart';

main() async {
  final Mercure mercure = Mercure(
    url: 'http://example.com/.well-known/mercure', // your mercure hub url
    topics: ['/books/{id}'], // your mercure topics
  );

  final subscription = mercure.listen((event) {
    print(event.data);
  });
}
8
likes
0
pub points
73%
popularity

Publisher

verified publisherherve-guigoz.com

Provide a quick way to publish and consume messages on Mercure

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

http

More

Packages that depend on mercure_client