mirror of
https://github.com/ryannhg/elm-spa.git
synced 2024-11-25 23:43:02 +03:00
Update routing.md
As per comments in PR.
This commit is contained in:
parent
f5cc8fb845
commit
48facd9ace
@ -15,8 +15,8 @@ URL | File
|
||||
In this section, we'll cover the 3 kinds of routes you can find in an __elm-spa__ application.
|
||||
|
||||
## The homepage
|
||||
|
||||
The `src/Pages/Home_.elm` file is a __dynamic route__ that's reserved and handles requests to `/`. The easiest way to make a new homepage is with the [`add` command](/guide/cli#adding-a-homepage) covered in the CLI section:
|
||||
|
||||
The `src/Pages/Home_.elm` is a reserved filename that handles requests to /. The easiest way to make a new homepage is with the [`add` command](/guide/cli#adding-a-homepage) covered in the CLI section:
|
||||
|
||||
```terminal
|
||||
elm-spa add /
|
||||
@ -103,4 +103,4 @@ It will handle any request to `/users/___/posts/___`
|
||||
|
||||
If a user visits a URL that doesn't have a corresponding page, it will redirect to the `NotFound.elm` page. This is generated for you by default in the `.elm-spa/defaults/Pages` folder. When you are ready to customize it, move it into `src/Pages` and customize it like you would any other page!
|
||||
|
||||
In __elm-spa__, this technique is called "ejecting" a default file. Throughout the guide, we'll find more default files that we might want to control in our project.
|
||||
In __elm-spa__, this technique is called "ejecting" a default file. Throughout the guide, we'll find more default files that we might want to control in our project.
|
||||
|
Loading…
Reference in New Issue
Block a user