update initial route documentation (#57136)
This commit is contained in:
@@ -404,10 +404,11 @@ class WidgetsApp extends StatefulWidget {
|
||||
/// Defaults to [Window.defaultRouteName], which may be overridden by the code
|
||||
/// that launched the application.
|
||||
///
|
||||
/// If the route contains slashes, then it is treated as a "deep link", and
|
||||
/// before this route is pushed, the routes leading to this one are pushed
|
||||
/// also. For example, if the route was `/a/b/c`, then the app would start
|
||||
/// with the three routes `/a`, `/a/b`, and `/a/b/c` loaded, in that order.
|
||||
/// If the route name starts with a slash and has multiple slashes in it, then
|
||||
/// it is treated as a "deep link", and before this route is pushed, the
|
||||
/// routes leading to this one are pushed also. For example, if the route was
|
||||
/// `/a/b/c`, then the app would start with the three routes `/a`, `/a/b`, and
|
||||
/// `/a/b/c` loaded, in that order.
|
||||
///
|
||||
/// Intermediate routes aren't required to exist. In the example above, `/a`
|
||||
/// and `/a/b` could be skipped if they have no matching route. But `/a/b/c` is
|
||||
|
||||
@@ -2151,9 +2151,10 @@ class Navigator extends StatefulWidget {
|
||||
/// This is the default value of [onGenerateInitialRoutes], which is used if
|
||||
/// [initialRoute] is not null.
|
||||
///
|
||||
/// If this string contains any `/` characters, then the string is split on
|
||||
/// those characters and substrings from the start of the string up to each
|
||||
/// such character are, in turn, used as routes to push.
|
||||
/// If this string starts with a `/` character and has multiple `/` characters
|
||||
/// in it, then the string is split on those characters and substrings from
|
||||
/// the start of the string up to each such character are, in turn, used as
|
||||
/// routes to push.
|
||||
///
|
||||
/// For example, if the route `/stocks/HOOLI` was used as the [initialRoute],
|
||||
/// then the [Navigator] would push the following routes on startup: `/`,
|
||||
|
||||
Reference in New Issue
Block a user