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

Warning, consider using: "Get.to(() => Page())" instead of "Get.to(Page())" #4

Open
zaenury opened this issue Apr 14, 2021 · 2 comments

Comments

@zaenury
Copy link

zaenury commented Apr 14, 2021

On Debug Console, "Using a widget function instead of a widget fully guarantees that the widget and its controllers will be removed from memory when they are no longer used."

image

Resolve :
In file: question_controller.dart & welcome_screen.dart

Instead of using
Get.to(ScoreScreen());
Get.to(QuizScreen())

Use
Get.to(() => ScoreScreen());
Get.to(() => QuizScreen())

@clusterDe
Copy link

On Debug Console, "Using a widget function instead of a widget fully guarantees that the widget and its controllers will be removed from memory when they are no longer used."

image

Resolve :
In file: question_controller.dart & welcome_screen.dart

Instead of using
Get.to(ScoreScreen());
Get.to(QuizScreen())

Use
Get.to(() => ScoreScreen());
Get.to(() => QuizScreen())

it's still error for me, any help?
Screen Shot 2021-05-07 at 03 33 07

@zaenury
Copy link
Author

zaenury commented May 12, 2021

@clusterDe Try to update your get package to the latest version:

https://pub.dev/packages/get/versions

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

No branches or pull requests

2 participants