|
|
@ -7,31 +7,34 @@ an article explaining Navigator 2.0.
|
|
|
|
|
|
|
|
|
|
|
|
**Navigator 1.0 samples**
|
|
|
|
**Navigator 1.0 samples**
|
|
|
|
|
|
|
|
|
|
|
|
* [nav_1/anonymous_routes.dart](lib/nav_1/anonymous_routes.dart) - Shows how to use a Navigator to push and pop
|
|
|
|
* [nav_1/anonymous_routes.dart](lib/nav_1/anonymous_routes.dart) - Shows how to
|
|
|
|
anonymous routes (e.g. MaterialPageRoute)
|
|
|
|
use a Navigator to push and pop anonymous routes (e.g. MaterialPageRoute)
|
|
|
|
* [nav_1/named_routes.dart](lib/nav_1/named_routes.dart) - Shows how to use define named routes via the `routes`
|
|
|
|
* [nav_1/named_routes.dart](lib/nav_1/named_routes.dart) - Shows how to use
|
|
|
|
parameter on MaterialApp, and navigate using Navigator.pushNamed
|
|
|
|
define named routes via the `routes` parameter on MaterialApp, and navigate
|
|
|
|
* [nav_1/on_generate_route.dart](lib/nav_1/on_generate_route.dart) - Shows how to handle arbitrary named routes
|
|
|
|
using Navigator.pushNamed
|
|
|
|
using the `onGenerateRoute` callback defined in the `MaterialApp` constructor.
|
|
|
|
* [nav_1/on_generate_route.dart](lib/nav_1/on_generate_route.dart) - Shows how
|
|
|
|
|
|
|
|
to handle arbitrary named routes using the `onGenerateRoute` callback defined
|
|
|
|
|
|
|
|
in the `MaterialApp` constructor.
|
|
|
|
|
|
|
|
|
|
|
|
**Navigator 2.0 samples**
|
|
|
|
**Navigator 2.0 samples**
|
|
|
|
|
|
|
|
|
|
|
|
* [nav_2/pages.dart](lib/nav_2/pages.dart) - Shows how to define a list of [Page] objects on Navigator
|
|
|
|
* [nav_2/pages.dart](lib/nav_2/pages.dart) - Shows how to define a list of
|
|
|
|
declaratively.
|
|
|
|
[Page] objects on Navigator declaratively.
|
|
|
|
* [nav_2/router.dart](lib/nav_2/router.dart) - Full sample that shows a custom RouteInformationParser
|
|
|
|
* [nav_2/router.dart](lib/nav_2/router.dart) - Full sample that shows a custom
|
|
|
|
and RouterDelegate parsing named routes and declaratively building the stack
|
|
|
|
RouteInformationParser and RouterDelegate parsing named routes and
|
|
|
|
of pages for the Navigator.
|
|
|
|
declaratively building the stack of pages for the Navigator.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
**Advanced**
|
|
|
|
**Advanced**
|
|
|
|
|
|
|
|
|
|
|
|
* [nav_2_advanced/nested_router.dart](lib/nav_2_advanced/nested_router.dart) - Shows two [RouterDelegate], one nested
|
|
|
|
* [nav_2_advanced/nested_router.dart](lib/nav_2_advanced/nested_router.dart) -
|
|
|
|
within the other. A [BottomNavigationBar] can be used to select the route of
|
|
|
|
Shows two [RouterDelegate], one nested within the other. A
|
|
|
|
the outer RouterDelegate, and additional routes can be pushed onto the inner
|
|
|
|
[BottomNavigationBar] can be used to select the route of the outer
|
|
|
|
|
|
|
|
RouterDelegate, and additional routes can be pushed onto the inner
|
|
|
|
RouterDelegate / Navigator.
|
|
|
|
RouterDelegate / Navigator.
|
|
|
|
* [nav_2_advanced/transition_delegate.dart](lib/nav_2_advanced/transition_delegate.dart) - Shows how a custom
|
|
|
|
* [nav_2_advanced/transition_delegate.dart](lib/nav_2_advanced/transition_delegate.dart)
|
|
|
|
TransitionDelegate can be used to customized when transition animations are
|
|
|
|
Shows how a custom TransitionDelegate can be used to customized when
|
|
|
|
shown.
|
|
|
|
transition animations are shown.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## Running
|
|
|
|
## Running
|
|
|
|