addRoutes method

void addRoutes(
  1. List<NyRouterRoute> routes
)

Add a list of routes at once.

Implementation

void addRoutes(List<NyRouterRoute> routes) {
  if (routes.isNotEmpty) {
    for (var route in routes) {
      _addRoute(route);
    }
  }
  NyNavigator.instance.router = this;
}