ionic-team / ionic-team/ionic-docs

React routing docs provide conflicting information on nested navigation

Offen
#1,604 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
triage
Vorherrschende Sprache
MDX
Sterne
621
Forks
3.2k
Ø Merge
1 T. 2 Std.
Gemergte PRs (30 T.)
86

Beschreibung

**URL**
https://ionicframework.com/docs/react/navigation

The React Navigation document contains a small bit of conflicting information (which caused me some confusion).

The docs first showcase an example of nested routing using `IonRouterOutlet`:
```jsx








```
with the `DashboardPage` component further down:
```jsx
const DashboardPage: React.FC = () => {
return (




);
};
```

So upon navigating to the `/dashboard` routes, we'd expect the `DashboardPage` component to work and allow for nested navigation.

However, this does **not** work properly. Indeed, the docs also say [below](https://ionicframework.com/docs/react/navigation#ionrouteroutlet):

> An `IonRouterOutlet` should also not be a descendant from another `IonRouterOutlet`.

In direct contradiction with what was showcased a few paragraphs above.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.