move transition into routing record

This commit is contained in:
Ryan Haskell-Glatz 2019-10-18 21:18:21 -05:00
parent 44cf861672
commit 1eb7e7688b
2 changed files with 4 additions and 4 deletions

View File

@ -9,10 +9,10 @@ import Layout as Layout
main : Application () Pages.Model Pages.Msg
main =
Application.create
{ transition = Application.fade 200
, routing =
{ routing =
{ fromUrl = Route.fromUrl
, toPath = Route.toPath
, transition = Application.fade 200
}
, layout =
{ view = Layout.view

View File

@ -53,8 +53,8 @@ create :
{ routing :
{ fromUrl : Url -> route
, toPath : route -> String
, transition : Transition (Html msg)
}
, transition : Transition (Html msg)
, layout :
{ view : { page : Html msg } -> Html msg
}
@ -68,7 +68,7 @@ create :
create config =
let
transition =
unwrap config.transition
unwrap config.routing.transition
in
Browser.application
{ init =