React routing docs provide conflicting information on nested navigation
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 45/100
- Issue type
- Documentation
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- react
- Domain
- documentation
Research direction
Start at the React navigation page and compare the nested routing examples with the IonRouterOutlet guidance below. Clarify or revise the conflicting documentation so the supported approach to nested navigation is unambiguous, then verify the rendered page explains the same behavior consistently.
Written by the indexing model from the issue text.
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:
<IonApp>
<IonReactRouter>
<IonRouterOutlet>
<Route path="/dashboard" component={DashboardPage} />
<Redirect exact from="/" to="/dashboard" />
</IonRouterOutlet>
</IonReactRouter>
</IonApp>
with the DashboardPage component further down:
const DashboardPage: React.FC = () => {
return (
<IonRouterOutlet>
<Route exact path="/dashboard" component={UsersListPage} />
<Route path="/dashboard/users/:id" component={UserDetailPage} />
</IonRouterOutlet>
);
};
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:
An
IonRouterOutletshould also not be a descendant from anotherIonRouterOutlet.
In direct contradiction with what was showcased a few paragraphs above.
- Dominant language
- MDX
- Stars
- 621
- Forks
- 3.2k
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 86
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ionic-team/ionic-docs
-
content
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
ionic-team/ionic-docs#4705 ·
-
content package: angular
Difficulty 2/5 Half a day Newbie friendliness 78/100
ionic-team/ionic-docs#4702 ·
-
triage
Difficulty 1/5 Under an hour Newbie friendliness 80/100
ionic-team/ionic-docs#4546 ·
-
content: broken link Opencontent
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
ionic-team/ionic-docs#4381 · 2 comments ·
-
triage
Difficulty 1/5 Under an hour Newbie friendliness 72/100
ionic-team/ionic-docs#3639 ·
All issues in ionic-team/ionic-docs
Similar issues
-
sync-en
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
agilepathway/label-checker#640 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
BasedHardware/omi#15662 · 1 comment ·
-
documentation help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 1/5 1-3 hours Newbie friendliness 88/100