We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When user navigate to Test3Route default back arrow is not displayed. What I did wrong?
Test3Route
Here my app_router code
@singleton @AutoRouterConfig(replaceInRouteName: 'Page,Route') class AppRouter extends RootStackRouter { AppRouter( this._authGuard, ); final AuthGuard _authGuard; @override RouteType get defaultRouteType => const RouteType.adaptive(); @override late final List<AutoRoute> routes = [ AutoRoute( page: DashboardWrapperRoute.page, path: '/', guards: [_authGuard], children: [ AutoRoute( page: Test1Route.page, path: 'test1', ), AutoRoute( page: Test2Route.page, path: 'test2', ), AutoRoute( page: TestWrapperRoute.page, path: 'test', children: [ AutoRoute(page: Test3Route.page, path: 'test3'), AutoRoute(page: Test4Route.page, path: 'test4'), ], ), ], ), ]; }
Here is my Pages code
@RoutePage() class Test1Page extends StatelessWidget { const Test1Page({super.key}); @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( title: Text('Test1 Page'), ), body: Center( child: FilledButton.tonal( onPressed: () { context.router.push(Test2Route()); }, child: Text('Test 2'), ), ), ); } } @RoutePage() class Test2Page extends StatelessWidget { const Test2Page({super.key}); @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( title: Text('Test2 Page'), ), body: Center( child: FilledButton.tonal( onPressed: () { context.router.push(Test3Route()); }, child: Text('Test 3'), ), ), ); } } @RoutePage() class TestWrapperPage extends StatelessWidget { const TestWrapperPage({super.key}); @override Widget build(BuildContext context) { return Provider<String>( create: (context) => 'test', child: const AutoRouter(), ); } } @RoutePage() class Test3Page extends StatelessWidget { const Test3Page({super.key}); @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( title: Text('Test3 Page ${context.read<String>()}'), ), body: Center( child: FilledButton.tonal( onPressed: () {}, child: Text('Test 4'), ), ), ); } } @RoutePage() class Test4Page extends StatelessWidget { const Test4Page({super.key}); @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( title: Text('Test4 Page'), ), body: Center( child: FilledButton.tonal( onPressed: () {}, child: Text('Home'), ), ), ); } }
The text was updated successfully, but these errors were encountered:
Do I have to use leading: AutoLeadingButton(), in this case?
leading: AutoLeadingButton(),
Sorry, something went wrong.
No branches or pull requests
When user navigate to
Test3Route
default back arrow is not displayed. What I did wrong?Here my app_router code
Here is my Pages code
The text was updated successfully, but these errors were encountered: