<!-- This file is generated from the source code and any changes you make here will be overwritten. For more information, refer to https://github.com/Shopify/shopify-dev/blob/master/content/internal/operations/hydrogen-reference-docs.md. -->
All components added to `src/pages` directory are registered as routes in `App.server.jsx`. Any filenames with brackets like `[handle]` are converted to a React Router parameter called `:handle`.
To obtain the `handle` from React Router, add the following code to `App.server.jsx`:
{% codeblock file, filename: 'App.server.jsx' %}
```jsx
import {useParams} from 'react-router-dom';
const {handle} = useParams();
```
{% endcodeblock %}
### Custom static implementation
You can also provide a custom static implementation of a dynamic page to override the default. Any requests to `/products/hoodie` are rendered using `hoodie.server.jsx` instead of `[handle].server.jsx`:
{% codeblock file, filename: 'src/pages' %}
```
/pages/products/hoodie.server.jsx
/pages/products/[handle].server.jsx
```
{% endcodeblock %}
## Catch all routes
You can extend dynamic routes to catch all paths by adding an ellipsis (...) inside the brackets. For example, `/pages/example/[...handle].server.jsx` will match `/example/a` and `/example/a/b`.
### Example
The following example shows how to obtain catch all routes data using `location.pathname`:
- Learn about [React Server Components](/api/hydrogen/framework/react-server-components), an opinionated data-fetching and rendering workflow for React apps.
- Learn how the [page server component](/api/hydrogen/framework/pages) receives props, which includes custom versions of `request` and `response`.