diff --git a/README.md b/README.md index 4c18be8..1363739 100644 --- a/README.md +++ b/README.md @@ -44,6 +44,7 @@ | impas | `import … as` | | let | `let … in …` | | mod | `module` | + | template | `elm-template` | | type | `type` | | typea | `type alias (Record)` | diff --git a/Snippets/template.sublime-snippet b/Snippets/template.sublime-snippet new file mode 100644 index 0000000..a24916d --- /dev/null +++ b/Snippets/template.sublime-snippet @@ -0,0 +1,62 @@ + + Model -> ( Model, Cmd Msg ) +update msg model = + ( model, Cmd.none ) + + + +---- VIEW ---- + + +view : Model -> Html Msg +view model = + div [] + [ img [ src "/logo.svg" ] [] + , h1 [] [ text "Your Elm App is working!" ] + ] + + + +---- PROGRAM ---- + + +main : Program () Model Msg +main = + Browser.element + { view = view + , init = \_ -> init + , update = update + , subscriptions = always Sub.none + } +]]> + elm-template + source.elm +