code: private function addIndexRoute(RouteCollection $routes, array $defaults): void
      {
          $route = new Route('/', $defaults);
  
          $this->addLocaleToRoute($route);
  
          $routes->add('contao_index', $route);
      }
docs: Adds a route to redirect a user to the index page.