slowly 0.2.0 copy "slowly: ^0.2.0" to clipboard
slowly: ^0.2.0 copied to clipboard

debounce and throttle

example/main.dart

import 'package:slowly/slowly.dart';

main() {
  final sly = Slowly<String>();

  /// debounce
  bool access1 =
      sly.duration('foo', SlowlyTp.debounce, const Duration(milliseconds: 100));
  bool access2 = sly.ms('foo', ms: 100, tp: SlowlyTp.debounce);
  bool access3 = sly.seconds('foo', sec: 1, tp: SlowlyTp.debounce);

  /// throttle
  bool access4 =
      sly.duration('foo', SlowlyTp.throttle, const Duration(milliseconds: 100));
}
1
likes
0
points
77
downloads

Publisher

unverified uploader

Weekly Downloads

debounce and throttle

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on slowly