The request here is for a simple escape hatch from Expo Router for files or folders within the /app directory. This would be modeled after the same transition made in web, most notable Next JS' move from the /pages router (slices) to /app router (co-location).
e.g.
my-app/
└── app/
└── posts/
├── _components/
│ ├── PostBody.tsx
│ └── AuthorCard.tsx
├── _hooks/
│ └── usePostData.ts
├── index.tsx <-- Route definition
└── [slug].tsx <-- Route definition
Application slices (Routes as /app, components/ + hooks/ + services/ etc all as mirrored directories) require tremendously more overhead and expose opportunities for divergence as an app grows as compared to co-location as displayed above.
Allowing folders and files to be escaped allows for everything pertaining to a specific feature to exist in the same place, elevating only elements that are truly shared in other places to a more global space.
What we have now is the equivalent of enforcing everything as "global state". This is very similar to how we already view scoping within code itself- place variables as close to where they are used as possible.