csells / go_router

The purpose of the go_router for Flutter is to use declarative routes to reduce complexity, regardless of the platform you're targeting (mobile, web, desktop), handling deep linking from Android, iOS and the web while still allowing an easy-to-use developer experience.
https://gorouter.dev
442 stars 96 forks source link

[Minor inconvenience] go_router import suggestion triggers warning #116

Closed s9th closed 2 years ago

s9th commented 2 years ago

Since 2.2.0 whenever go_router method is used without importing package before, vscode import suggests import 'package:go_router/src/go_router.dart';

image

This in turn produces a warning if corresponding analysis option is enabled, so you need to manually change the import to 'package:go_router/go_router.dart' image

csells commented 2 years ago

@s9th that is a bug for sure! @kevmoo what did you do??? : )

kevmoo commented 2 years ago

It's a bug – in analyzer!

https://pub.dev/documentation/go_router/latest/go_router/GoRouterHelper.html

The extension class is exported correctly!

I could imagine this being an edge case w/ extension types – since they are new-ish.

csells commented 2 years ago

@s9th this should be fixed in v2.2.4. can you confirm?

s9th commented 2 years ago

can confirm, thank you