Skip to content
New issue

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

add go_router in Navigation category #883

Merged
merged 3 commits into from
Dec 11, 2021
Merged

add go_router in Navigation category #883

merged 3 commits into from
Dec 11, 2021

Conversation

gmeligio
Copy link
Contributor

@gmeligio gmeligio commented Dec 9, 2021

Description

https://github.com/csells/go_router

go_router it's a great router package for Flutter navigation. I think that the awesome list should include it in the Navigation category.

The feature that shines the most is easy to write declarative routes. It has features like integration with Flutter Navigator 2.0, deep linking, error handling, redirection, route debugging, nested navigation, etc. All of these features are well documented on the documentation website https://gorouter.dev/

import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';

class App extends StatelessWidget {
  App({Key? key}) : super(key: key);

  final _router = GoRouter(
    routes: [
      GoRoute(
        path: '/',
        builder: (context, state) => const Page1Screen(),
      ),
      GoRoute(
        path: '/page2',
        builder: (context, state) => const Page2Screen(),
      ),
    ],
  );

  @override
  Widget build(BuildContext context) => MaterialApp.router(
        routeInformationParser: _router.routeInformationParser,
        routerDelegate: _router.routerDelegate,
      );
}

Checklist

  • I read How to contribute
  • I edited the SOURCE.md file only
  • Added a link to the repo in the PR

@Solido
Copy link
Owner

Solido commented Dec 11, 2021

Thanks you for the addition! @gmeligio

@Solido Solido merged commit 79583bf into Solido:master Dec 11, 2021
@gmeligio
Copy link
Contributor Author

Great work! Thank you for merging @Solido.

@Solido
Copy link
Owner

Solido commented Dec 12, 2021

Thx @csells

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants