diff options
| author | Jan Tuomi <jan.tuomi@valuemotive.com> | 2021-11-04 18:06:11 +0200 |
|---|---|---|
| committer | Jan Tuomi <jan.tuomi@valuemotive.com> | 2021-11-04 18:06:11 +0200 |
| commit | 270123cc18ee8acff4b2819f4a609045bd5194f5 (patch) | |
| tree | 650fb26ac317b2697c1e91ce43682674e0ea874c /src/Routes.elm | |
| parent | 69d48eb332ac53104cf57b408059a103151071fb (diff) | |
Add navigation and profile
Diffstat (limited to 'src/Routes.elm')
| -rw-r--r-- | src/Routes.elm | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/Routes.elm b/src/Routes.elm new file mode 100644 index 0000000..04c7eb1 --- /dev/null +++ b/src/Routes.elm @@ -0,0 +1,12 @@ +module Routes exposing (..) + +import Types exposing (Route(..)) +import Url.Parser exposing ((</>), Parser, oneOf, s, string, top) + + +routeParser : Parser (Route -> a) a +routeParser = + oneOf + [ Url.Parser.map Index top + , Url.Parser.map Profile (s "profile" </> string) + ] |
