You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Plague Fox edited this page Jan 9, 2024
·
2 revisions
Use the context.octopus.setState((state) => ...) method as a basic navigation method.
And realize any navigation logic inside the callback as you please.
context.octopus.setState((state) =>
state
..findByName('catalog-tab')?.add(Routes.category.node(
arguments:<String, String>{'id': category.id},
)));
Of course, there are other ways to navigate, primarily shortcuts for the most common cases.
context.octopus.push(Routes.shop)
But you can truly do anything you want.
Just change the state, children, nodes, and arguments as you please.
Everything is in your hands and just works fine, that's a declarative approach as it should be.