flutter_use 1.0.0 copy "flutter_use: ^1.0.0" to clipboard
flutter_use: ^1.0.0 copied to clipboard

Essential Flutter hooks collection with 36 production-ready hooks for async operations, form management, UI interactions, and state management.

flutter_use

flutter_lints
Inspired by react-use.


A collection of Flutter Hooks inspired by React's react-use library. This monorepo contains multiple packages providing different categories of hooks for Flutter development.

πŸ“¦ Packages #

Package Description Version
flutter_use Core hooks library with essential utilities pub package
flutter_use_audio Audio playback and control hooks pub package
flutter_use_battery Battery state monitoring hooks pub package
flutter_use_geolocation Location and permission hooks pub package
flutter_use_network_state Network connectivity hooks pub package
flutter_use_sensors Device sensors hooks pub package
flutter_use_video Video playbook hooks pub package

πŸš€ Installation #

For the core package:

flutter pub add flutter_use

For specialized packages:

flutter pub add flutter_use_audio    # Audio hooks
flutter pub add flutter_use_battery  # Battery hooks
# ... and so on

🌐 Interactive Demo Site #

Try out all hooks with live examples at: https://wasabeef.github.io/flutter_use/

πŸ“š Hooks by Category #

πŸ“± Mobile-first Hooks #

Core package: flutter_use

  • useAsync β€” manages async operations with loading, data, and error states.
  • useDebounceFn β€” debounces function calls for better performance.
  • useInfiniteScroll β€” implements infinite scrolling with automatic loading.
  • useForm β€” comprehensive form state management with validation.
  • useKeyboard β€” tracks keyboard visibility and manages layouts (mobile only).

🎭 State Management #

Core package: flutter_use

⏱️ Timing & Animation #

Core package: flutter_use

πŸ”„ Side Effects & Performance #

Core package: flutter_use

🎯 UI Interactions #

Core package: flutter_use

♻️ Lifecycle Management #

Core package: flutter_use

🎨 Development & Debugging #

Core package: flutter_use

  • useLogger β€” logs in console as component goes through life-cycles.

πŸ“± Device Sensors #

Package: flutter_use_sensors

Core package: flutter_use

πŸ”‹ Device Information #

Package: flutter_use_battery

Package: flutter_use_geolocation

  • useGeolocation β€” tracks geo location and permission state of user's device. geolocator

Package: flutter_use_network_state

🎡 Media #

Package: flutter_use_audio

  • useAudio β€” plays audio and exposes its controls. just_audio

Package: flutter_use_video

🚧 Coming Soon #

  • useEvent β€” subscribe to events.
  • useFullscreen β€” display an element or video full-screen.
  • usePageLeave β€” triggers when mouse leaves page boundaries.
  • usePermission β€” query permission status for apps APIs.
  • useMethods β€” neat alternative to useReducer.
  • useSetState β€” creates setState method which works like this.setState.
  • usePromise β€” resolves promise only while component is mounted.
  • useObservable β€” tracks latest value of an Observable.



Unlicense β€” public domain.



73
likes
150
points
3.17k
downloads

Publisher

verified publisherwasabeef.jp

Weekly Downloads

Essential Flutter hooks collection with 36 production-ready hooks for async operations, form management, UI interactions, and state management.

Repository (GitHub)
View/report issues

Documentation

Documentation
API reference

License

Unlicense (license)

Dependencies

flutter, flutter_hooks

More

Packages that depend on flutter_use