builder_state 0.0.4
builder_state: ^0.0.4 copied to clipboard
A simple and customizable Flutter package to easily handle different states (loading, success, error, no data) when working with asynchronous operations like FutureBuilder. Includes ready-to-use widge [...]
Changelog #
All notable changes to this project will be documented in this file.
0.0.4 #
Added #
- Introduced
FutureLoader<T>
widget to simplifyFutureBuilder
handling with:- Customizable success state with data (
onSuccessHasData
). - Optional handler for success state with no data (
onSuccessNoData
). - Custom error state handling via
onError
or fallback toErrorMsgBuilder
. - Custom waiting state handling via
onWaiting
or fallback toLoadingScreen
.
- Customizable success state with data (
- Support for optional titles:
noDataTitle
,errorTitle
, and waiting messagewaitingTxt
.
This is the first stable version.
0.0.1 #
Initial Release #
- Added
FutureLoader
widget for managing async data states (loading, success, error, and no data). - Added
LoadingScreen
widget to display a loading spinner or custom waiting text. - Added
NoItemScreen
widget to display a "No Item" message when no data is available. - Included default error and waiting handlers (
defaultOnError
anddefaultOnWaiting
). - Provided customizations for error, loading, and no data states.
- Integrated with
state_msg_builder
for message rendering.
Features #
- Simplified async state management for Flutter applications.
- Flexible error handling with different error messages.
- Easy integration with
FutureBuilder
to display different states.