-
-
Save Ikechukwunwachukwu/e22c7009370d9f0bab5e825efbc14abe to your computer and use it in GitHub Desktop.
Basic skeleton of an Elm sandbox application
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main exposing (main) | |
import Browser | |
import Html exposing (Html, text) | |
main : Program () Model Msg | |
main = | |
Browser.sandbox | |
{ init = myInit | |
, view = myView | |
, update = myUpdate | |
} | |
-- MODEL | |
type alias Model = | |
{} | |
myInit : Model | |
myInit = | |
{} | |
-- VIEW | |
myView : Model -> Html Msg | |
myView model = | |
text "It works!" | |
-- UPDATE | |
type Msg | |
= NoOp | |
myUpdate : Msg -> Model -> Model | |
myUpdate msg model = | |
case msg of | |
NoOp -> | |
model |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment