/go_router_riverpod

An example on how to use Riverpod + GoRouter

Primary LanguageDart

go_router_example

A simple login / logout examples that showcases the use of Riverpod with GoRouter. This example exploits the usage of ref.listen and a ChangeNotifier to update the Router's decisions.

NOTE. After the GoRouter v5 changes, I strongly recommend to just look at the Routers v1 (synchronous redirects) and v4 (asynchronous redirects).

Please consider starring this mini-repo if you found it useful. If you didn't, or if you want to contribute in any way, a discussion about improving this example can be found here.