Skip to content

riverpod architecture/design pattern advice #1137

Discussion options

You must be logged in to vote
  throw AsyncError<Exception>(e, stackTrace: st);

This is a bit weird. I don't see the purpose of this code. Maybe you wanted to do state = AsyncError(...)?

Other than that, your code looks alright.
Riverpod is a pattern on its own. You're not using "Riverpod + ". Riverpod is the pattern, since it's fairly strict in what you can and can't do

As for testing your code, I'd suggest looking at the testing cookbook or some of Riverpod's tests.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@rrousselGit
Comment options

@varunbhalerao56
Comment options

@rrousselGit
Comment options

Answer selected by varunbhalerao56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
documentation Improvements or additions to documentation needs triage
2 participants
Converted from issue

This discussion was converted from issue #1080 on January 29, 2022 12:18.