소스 검색

updated elm project template

Brandon Wong 7 년 전
부모
커밋
0490108d16
2개의 변경된 파일24개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 0
      elm/.gitignore
  2. 23 1
      elm/Main.elm

+ 1 - 0
elm/.gitignore

@@ -1,3 +1,4 @@
 .idea
 *.swp
 elm-stuff
+client.js

+ 23 - 1
elm/Main.elm

@@ -6,17 +6,39 @@ import Html.Events exposing (..)
 import Html.Attributes exposing (id, class, classList)
 
 
+type alias Model =
+    {
+    }
+
+initModel : Model
+initModel =
+    {
+    }
+
+
+type Msg
+    = NoOp
+
+
+view : Model -> Html Msg
 view model =
     div
         []
         [ text "$foldername" ]
 
+update : Msg -> Model -> (Model, Cmd Msg)
 update msg model =
     ( model, Cmd.none )
 
+--subscriptions : Model -> Sub Msg
+--subscriptions model =
+--    Sub.batch
+--        [
+--        ]
+
 main =
     Html.program
-        { init = ("", Cmd.none)
+        { init = (initModel, Cmd.none)
         , view = view
         , update = update
         , subscriptions = \_ -> Sub.none