fancy_stream 1.1.0+3 copy "fancy_stream: ^1.1.0+3" to clipboard
fancy_stream: ^1.1.0+3 copied to clipboard

outdated

A sophisticated way to use streams, make it even easier to use, highly recommended for use in Bloc Pattern, as it contains functions for easy use of stream / sink dispatch / listen to work with stream [...]

example/example.dart

import 'package:fancy_stream/fancy_stream.dart';

class Example extends Disposable {

  void main(List<String> args) {    
    //listen something on String, with key = "print"
    listenOn<String>(printWhenDispatchedValue, key:"print");
    dispatchOn<String>("Print that!", key: "print");


    listenOn<String>(printWhenDispatchedValue);
    dispatchOn<String>("Print that without key!");

    ///Clean all Subjects, Subscrtiption and instances generated
    dispose();
  } 

  void printWhenDispatchedValue(String value) {
    print(value);
  }
}
7
likes
0
points
6
downloads

Publisher

unverified uploader

Weekly Downloads

A sophisticated way to use streams, make it even easier to use, highly recommended for use in Bloc Pattern, as it contains functions for easy use of stream / sink dispatch / listen to work with streams without boilerplate.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter_simple_dependency_injection, meta, rxdart

More

Packages that depend on fancy_stream