subscribeWithPrevious<A> abstract method

void subscribeWithPrevious<A>(
  1. Atom<A> atom,
  2. void handler(
    1. A? previous,
    2. A value
    ), {
  3. bool fireImmediately = false,
})

Subscribe to the given atom, automatically cancelling the subscription when this atom is disposed.

Implementation

void subscribeWithPrevious<A>(
  Atom<A> atom,
  void Function(A? previous, A value) handler, {
  bool fireImmediately = false,
});