blob: 0ed4203493f120b0ca96b84cdde7e303b7948924 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
module Route
( Route(..)
, matchers
, toPath
) where
import Effects exposing (Effects)
import RouteParser exposing (..)
type Route =
Empty
| Home
| Income
| Stat
matchers : List (Matcher Route)
matchers =
[ static Empty ""
, static Home "/"
, static Income "/income"
, static Stat "/statistics"
]
toPath : Route -> String
toPath route =
case route of
Empty -> ""
Home -> "/"
Income -> "/income"
Stat -> "/statistics"
|