withNext method

ShellValue withNext(
  1. RouteNode<RouteValue> next
)

Implementation

ShellValue withNext(RouteNode next) {
  return ShellValue(
    key: key,
    tabIndex: tabNodes.indexWhere((tab) => tab.value.key == next.value.key),
    tabNodes: tabNodes
        .map((e) => e.value.key == next.value.key ? next : e)
        .toList(),
  );
}