Skip to main content

ephemeral_value 2.0.0 copy "ephemeral_value: ^2.0.0" to clipboard
ephemeral_value: ^2.0.0 copied to clipboard

Ephemeral value types for Dart and Flutter. Easily represent loading, success, error, empty, and initial states in your app logic and UI.

2.0.0 #

Breaking changes #

  • Ephemeral.toInitial and Ephemeral.toSuccess now require an explicit non-null T as the first argument. Optional value parameters and implicit “retain current value” behavior for these transitions are removed. Update call sites to pass the value for the new state (for example toSuccess(ephemeral.value!) when reusing the current payload), or use toInitialFallback / toSuccessFallback (see Added).

Added #

  • Ephemeral.toInitialFallback and Ephemeral.toSuccessFallback — transition to initial/success using the current value without passing it (optional message). Asserts in debug mode if the current value is null.

1.2.2 #

  • Fixed issue with extension methods not accessible by projects.

1.2.1 #

  • Added new unit test for new utility methods.

1.2.0 #

  • Added more utility methods to EphemeralValue

1.1.0 #

  • Added new builtin ephemeral states: RefreshingValue and StaleValue

1.0.0 #

  • Initial version.
1
likes
160
points
146
downloads

Documentation

API reference

Publisher

verified publisherxamantra.dev

Weekly Downloads

Ephemeral value types for Dart and Flutter. Easily represent loading, success, error, empty, and initial states in your app logic and UI.

Repository (GitHub)
View/report issues

Topics

#state-management #value #loading #dart #flutter

License

BSD-3-Clause (license)

Dependencies

equatable

More

Packages that depend on ephemeral_value