Refactor RouterDelegate attempt 2 (#2189)

* Revert "Revert "[go_router] Refactor RouterDelegate into functional pieces (#1653)" (#2183)"

This reverts commit d39ffb1c93d2362ec95225422193c813f244a8bb.

* [go_router] Continue searching for top-level routes if the recursive search doesn't find any

* Remove Route.push from demo app

* update CHANGELOG.md

* Avoid pushing the same page in example

bump go_router_builder to 1.0.5

* Change published version to 4.0.0

* Specify dart SDK version >=2.17.0 to avoid analyzer errors

Analyzing go_router...

  error - lib/src/go_route_information_provider.dart:24:41 - A value of type 'WidgetsBinding?' can't be returned from the function '_binding' because it has a return type of 'WidgetsBinding'. - return_of_invalid_type
  error - lib/src/go_router.dart:51:33 - The property 'platformDispatcher' can't be unconditionally accessed because the receiver can be 'null'. Try making the access conditional (using '?.') or adding a null check to the target ('!'). - unchecked_use_of_nullable_value

2 issues found.

* Specify flutter >=3.0.0 in go_router

* Apply suggestions from code review

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>

* Apply suggestions from code review

* Update packages/go_router/lib/src/go_route_information_parser.dart

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>

* Update packages/go_router/lib/src/go_route_information_parser.dart

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>

* Update packages/go_router/lib/src/go_route_information_parser.dart

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>

* Update packages/go_router/lib/src/go_route_information_parser.dart

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>

* Add '/' route to test

* add go_route_information_provider_test.dart

* Add test for redirect detection in GoRouteInformationParser

* format

Co-authored-by: Loïc Sharma <737941+loic-sharma@users.noreply.github.com>
45 files changed
tree: 6cf74733aee486685d03cd02749bbef3357288f0
  1. .ci/
  2. .github/
  3. packages/
  4. script/
  5. third_party/
  6. .ci.yaml
  7. .cirrus.yml
  8. .clang-format
  9. .gitattributes
  10. .gitignore
  11. .gitmodules
  12. .metadata
  13. analysis_options.yaml
  14. AUTHORS
  15. CONTRIBUTING.md
  16. customer_testing.bat
  17. customer_testing.sh
  18. LICENSE
  19. README.md
README.md

Flutter Packages

Build Status Release Status

This repo is a companion repo to the main flutter repo. It contains the source code for Flutter's first-party packages (i.e., packages developed by the core Flutter team). Check the packages directory to see all packages.

These packages are also available on pub.

Issues

Please file any issues, bugs, or feature requests in the main flutter repo.

Contributing

If you wish to contribute a new package to the Flutter ecosystem, please see the documentation for developing packages. You can store your package source code in any GitHub repository (the present repo is only intended for packages developed by the core Flutter team). Once your package is ready you can publish to the pub repository.

If you wish to contribute a change to any of the existing packages in this repo, please review our contribution guide, and send a pull request.

Packages

These are the available packages in this repository.

PluginPubIssuesPull requests
animationspub packageGitHub issues by-labelGitHub pull requests by-label
css_colorspub packageGitHub issues by-labelGitHub pull requests by-label
extension_google_sign_in_as_googleapis_authpub packageGitHub issues by-labelGitHub pull requests by-label
fuchsia_ctlpub packageGitHub issues by-labelGitHub pull requests by-label
flutter_imagepub packageGitHub issues by-labelGitHub pull requests by-label
flutter_lintspub packageGitHub issues by-labelGitHub pull requests by-label
flutter_markdownpub packageGitHub issues by-labelGitHub pull requests by-label
go_routerpub packageGitHub issues by-labelGitHub pull requests by-label
go_router_builderpub packageGitHub issues by-labelGitHub pull requests by-label
multicast_dnspub packageGitHub issues by-labelGitHub pull requests by-label
palette_generatorpub packageGitHub issues by-labelGitHub pull requests by-label
pigeonpub packageGitHub issues by-labelGitHub pull requests by-label
pointer_interceptorpub packageGitHub issues by-labelGitHub pull requests by-label
xdg_directoriespub packageGitHub issues by-labelGitHub pull requests by-label