This repository was archived by the owner on Mar 17, 2025. It is now read-only.
How do I stop expo-router/drawer from rendering all routes? #916
Unanswered
byoungdale
asked this question in
Q&A
Replies: 3 comments
-
|
What worked for me was hide the route in style. return (
<Drawer drawerContent={RootDrawerContent}>
{/* ... */}
{/* Removing routes */}
<Drawer.Screen
name='[...missing]'
options={{ drawerItemStyle: { display: 'none' } }}
/>
<Drawer.Screen
name='item/[id]'
options={{ drawerItemStyle: { display: 'none' } }}
/>
</Drawer>
); |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Is that it? Is that the fix? Feels weird that it doesn't play nicely with expo-router. I would imagine dynamic routes wouldn't show up automatically on the drawer almost ever? Sucks if your app scales to quite a few routes too... |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
yes it sucks |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I only want to have the screens defined inside Drawer to render in the drawer.
I have this layout in my app dir:
. ├── +html.tsx ├── [...missing].tsx ├── _layout.tsx ├── item │ └── [id].tsx ├── feed │ ├── _layout.tsx │ └── index.tsx └── index.tsxAnd the
[...missing].tsxanditem/[id].tsxshow up in the drawer. How do I stop that?Beta Was this translation helpful? Give feedback.
All reactions