Skip to content

Commit

Permalink
Fix some stuff in catch-all docs (#897)
Browse files Browse the repository at this point in the history
  • Loading branch information
brenelz authored Sep 26, 2024
1 parent cfbe675 commit c25810d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/routes/solid-start/building-your-application/routing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,8 @@ They are defined using square brackets with `...` before the label for the route
```

A catch-all route will have one parameter which is a forward-slash delimited string of all the URL segments after the last valid segment.
For example, with the route `[..post]` and a URL path of `/post/foo` the `params` object returned from the `useParams` primitive will have a `post` property with the value of `foo`.
For a URL path of `/post/foo/baz` it will be `foo/baz`.
For example, with the route `[...post]` and a URL path of `/post/foo` the `params` object returned from the `useParams` primitive will have a `post` property with the value of `post/foo`.
For a URL path of `/post/foo/baz` it will be `post/foo/baz`.

```tsx title="routes/blog/[...post].tsx"
import { useParams } from "@solidjs/router";
Expand Down

0 comments on commit c25810d

Please sign in to comment.