flutter_page_transition
flutter_page_transition copied to clipboard
leftToRightJoined: _dependents.isEmpty
I'm getting several errors when attempting to use leftToRightJoined.
- _dependents.isEmpty'
- Duplicate Global Key detected
- '_elements.contains(element)': is not true.
In Main, onGenerateRoute the switch statement for that route is:
case '/set_alarm':
return PageTransition<dynamic>(
child: SetAlarmScreen(key: key),
type: PageTransitionType.leftToRightJoined,
childCurrent: this,
settings: settings,
duration: const Duration(seconds: 1),
);
I can't seem to find out where this issue is coming from, and it only affects the joined transitions. Any ideas?
What about removing key value on your SetAlarmScreen screen ?
It appeared to be a global navigator key that I had for something else. This has been removed as it's no longer needed.
Though whilst it's now working, it appears to be combining the wrong screens. It's combining screens from earlier in the navigation stack. I'm not sure what I'm doing wrong there?
I can't help without more details. This is the first time I've heard of it, maybe you should try flutter clean and recompile.
I've tried that I'm afraid. I'm pretty sure it has something to do with the nav stack. Here's a short video of my app from splash screen.
It goes: Splash screen -> Splash Screen (with animation) -> pushNamedAndRemoveUntil -> IntroScreen -> pushNamedAndRemoveUntil -> HomeScreen -> pushNamed (this is the one with the page transition or leftToRightJoined) -> setAlarm.
As you can see in the video you see previous screens from this nav stack, that should be removed?
Is there any other information I can provide to help?