notification_dispatcher 0.4.0 copy "notification_dispatcher: ^0.4.0" to clipboard
notification_dispatcher: ^0.4.0 copied to clipboard

Inspired by Apple's NotificationCenter. Passes information around to registered observers.

0.4.0 #

Breaking #

  • Removed support for Equatable.
  • Removed support for Future-based callbacks.
  • Removed MockNotificationDispatcher
  • remove has been renamed to removeObserverWith with the Object observer parameter made positional.

Documentation #

  • Updated documentation for removeObserver and removeObserverWith (previously called remove).

0.3.2 #

Fix #

  • Fix an issue where calling NotificationDispatcher.post could return earlier than intended.

Tests #

  • Added tests for Future callbacks.

0.3.1 (retracted) #

Fix #

  • Fix failing tests due to Futures running concurrently.

0.3.0 (retracted) #

Features #

  • Allow callbacks that return a Future.

0.2.1 #

Others #

  • Updated license.

0.2.0 #

Features #

  • Added a NotificationDispatcherEquatableObserverMixin to ensure classes that extend Equatable are able to be differentiated when adding/removing observers. To use, make sure the mixin's instanceKey is part of the class's props property.

Fixes #

  • Fixed an issue where notifications could not be differentiated between instances of the same class if its == operator and hashCode method were overriden.

Documentation #

  • Updated documentation to reflect changes.

Tests #

  • Added tests for observers that extend Equatable.

Others #

  • Updated pubspec description.

0.1.0 #

Features #

  • NotificationDispatcher.post now sends along a NotificationMessage to the observer.

Fixes #

  • Fixed an issue where notifications could not be differentiated between instances of the same class.

Documentation #

  • Added documentation for all NotificationDispatcher methods.

Workflow #

  • Added CI to run tests on commit.
  • Added some linting options.

0.0.1 #

  • Initial pre-release.
5
likes
160
points
79
downloads

Publisher

unverified uploader

Weekly Downloads

Inspired by Apple's NotificationCenter. Passes information around to registered observers.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

More

Packages that depend on notification_dispatcher