mirror of
https://github.com/dillonkearns/elm-pages-v3-beta.git
synced 2024-12-27 05:44:17 +03:00
Update logout button.
This commit is contained in:
parent
517acbce9d
commit
d594cdcc60
@ -165,11 +165,11 @@ view maybeUrl sharedModel model static =
|
|||||||
, Html.text <| "Hello " ++ static.data.username ++ "!"
|
, Html.text <| "Hello " ++ static.data.username ++ "!"
|
||||||
, Html.text <| "Requested page at " ++ String.fromInt (Time.posixToMillis static.data.requestTime)
|
, Html.text <| "Requested page at " ++ String.fromInt (Time.posixToMillis static.data.requestTime)
|
||||||
, Html.div []
|
, Html.div []
|
||||||
[ Html.form [ Attr.method "post", Attr.action "/logout", onSubmit (Logout |> Pages.Msg.UserMsg) ]
|
[ Html.form
|
||||||
[ Html.button
|
-- TODO use client-side form submission
|
||||||
[ Attr.type_ "submit" ]
|
-- TODO should there be a helper function to easily invoke a form submission to a different route?
|
||||||
[ Html.text "Logout" ]
|
[ Attr.method "post", Attr.action "/logout" ]
|
||||||
]
|
[ Html.button [] [ Html.text "Logout" ] ]
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user