riverpod icon indicating copy to clipboard operation
riverpod copied to clipboard

Add AsyncValue documentation

Open snapsl opened this issue 2 months ago • 6 comments

Make riverpod onboarding easier.

AsyncValue is a core feature of riverpod when we use AsyncNotifier / FutureProvider, but is not explained in the documentation. Currently new user have to look into the api reference or source code to get basic information.

The documentation should contain:

  • what is AsyncValue
    • utiltiy class
    • AsyncData /AsyncLoading / AsyncError
  • how to use AsyncValue
    • modifying an async value
    • .guard()
    • resolve async value (map / pattern matching / value / valueOrNull)

In case information is missing, feel free to add them.

If needed, I can contribute to the docs.

snapsl avatar Apr 24 '24 05:04 snapsl