@@ -710,7 +710,7 @@ Do not use dynamic routes when:
710710` DYNAMIC_ROUTES ` in ` src/ROUTES.ts ` : each entry has :
711711
712712- ` path ` : The URL suffix (e .g . ` 'verify-account' ` ).
713- - ` entryScreens ` : List of screen names that are allowed to have this suffix appended (access control ; see [Entry Screens (Access Control )](#entry - screens - access - control )).
713+ - ` entryScreens ` : List of screen names that are allowed to have this suffix appended (access control ; see [Entry Screens (Access Control )](#entry - screens - access - control )). Use ` ['*'] ` to allow all screens .
714714
715715` createDynamicRoute(suffix) ` — [` createDynamicRoute.ts ` ](src / libs / Navigation / helpers / createDynamicRoute .ts ). Accepts a ` DynamicRouteSuffix ` (from ` DYNAMIC_ROUTES ` ), appends it to the current active route and returns the full route . Use the following when navigating to a dynamic route :
716716
@@ -731,6 +731,24 @@ When parsing a URL, `src/libs/Navigation/helpers/getStateFromPath.ts` resolves t
731731
732732When adding or extending a dynamic route , list every screen that should be able to open it (e .g . ` SCREENS.SETTINGS.WALLET.ROOT ` for Verify Account from Wallet ).
733733
734+ #### Wildcard access (` '*' ` )
735+
736+ Setting ` entryScreens ` to ` ['*'] ` grants access to the dynamic route from any screen . This bypasses per - screen authorization entirely for that route .
737+
738+ ` ` ` ts
739+ KEYBOARD_SHORTCUTS: {
740+ path: 'keyboard-shortcuts',
741+ entryScreens: ['*'],
742+ },
743+ ` ` `
744+
745+ > [! CAUTION ]
746+ > ** Use ` '*' ` only when the dynamic route genuinely needs to be reachable from every screen .**
747+ > If only a subset of screens should access the route , list them explicitly .
748+ > Overusing ` '*' ` weakens the access control that ` entryScreens ` provides
749+ > and makes it harder to reason about which screens can trigger a given flow .
750+ > When in doubt , prefer an explicit list .
751+
734752### Current limitations (work in progress )
735753
736754- ** Path parameters :** Suffixes must not include path params (e .g . ` a/:reportID ` ). Query parameters are supported - see [Dynamic routes with query parameters ](#dynamic - routes - with - query - parameters ).
0 commit comments