Throttle constructor Null safety

Throttle(
  1. Function func,
  2. Duration wait,
  3. {bool leading = true,
  4. bool trailing = true}
)

Creates a new instance of Throttle

Implementation

Throttle(
  Function func,
  Duration wait, {
  bool leading = true,
  bool trailing = true,
}) : _debounce = Debounce(
        func,
        wait,
        leading: leading,
        trailing: trailing,
        maxWait: wait,
      );