Reputation: 1344
This happens on a simple back press. The back button brings it back to the dashboard. Strangely, coming back to the dashboard from other screens doesn't cause this lag.
I am not sure what (part of) code to post here.
Upvotes: 0
Views: 1194
Reputation: 852
this is happening because of your emulator is laggy not your appliction,
or you can disable the transition and check the app still lagging or not,
Navigator.pushReplacement(
context,
PageRouteBuilder(
pageBuilder: (context, animation1, animation2) => Page1(),
transitionDuration: Duration(seconds: 0),
),
);
use this code to disable navigator animation, if the app still lagging a bit, then thats your emulator's problem try clear the cache or memmory or upgrade your memory. or try reboot your emulator.
IMPORTENT : this lagging problem will fix after the release of this app so dont worry about that now,
try
flutter run --release
to release your app
Upvotes: 1