ionic-team / ionic-team/ionic-docs

React routing docs provide conflicting information on nested navigation

Ouverte
#1,604 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
triage
Langage dominant
MDX
Étoiles
621
Forks
3.2k
Merge moyen
1 j 2 h
PR mergées (30 j)
86

Description

**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.

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.