isRoot static method

Future<bool> isRoot(
  1. String routeName
)

判断路由routeName是否为根路由

Implementation

static Future<bool> isRoot(String routeName) async {
  String? rootName = await rootRouteName();
  return rootName != null && rootName == routeName;
}