select<B> method

PodNotifier<Pod<T>, B> select<B>(
  1. B cb(
    1. T value
    )
)

Create a derived pod, that transforms a pod's value using the given function cb.

Only rebuilds when the selected value changes.

Implementation

PodNotifier<Pod<T>, B> select<B>(B Function(T value) cb) => PodNotifier(
      this,
      (ref, parent) => cb(
        ref.watch(parent),
      ),
    );