-- A button that moves to random positions when pressed.
--
-- Dependencies:
-- elm install elm/random
import Browser
import Html exposing (..)
import Html.Attributes exposing (..)
import Html.Events exposing (..)
import Random
-- MAIN
main =
Browser.element
{ init = init
, update = update
, subscriptions = subscriptions
, view = view
}
-- MODEL
type alias Model =
{ x : Int
, y : Int
init : () -> (Model, Cmd Msg)
init _ =
( Model 100 100
, Cmd.none
)
-- UPDATE
type Msg
= Clicked