elm effects,tick函数显然从未被调用

elm effects,tick函数显然从未被调用,elm,Elm,我试图让我的模型对时钟信号做出反应,以便制作一些动画,如elm体系结构教程的示例8(旋转立方体) 由于我的程序不起作用,我试图用最简单的例子来说明我的问题 module Test where import Html exposing (..) import Html.Events exposing (..) import StartApp as StartApp import Effects exposing (..) import Time exposing (..) type ali

我试图让我的模型对时钟信号做出反应,以便制作一些动画,如elm体系结构教程的示例8(旋转立方体)

由于我的程序不起作用,我试图用最简单的例子来说明我的问题

module Test where

import Html exposing (..)
import Html.Events exposing (..)
import StartApp as StartApp
import Effects exposing (..)
import Time exposing (..) 

type alias Model =
 {debug : String}

type Action = 
 Start | Tick Time

initialModel = Model "initial"

update : Action -> Model -> (Model, Effects Action)
update action model =
  case action of
    Start  -> ({model | debug = "started"}, Effects.tick Tick)
    Tick _ -> ({model | debug = "hasTicked"}, Effects.none)

view : Signal.Address Action -> Model -> Html
view address model =
  div []
      [ button [onClick address Start] [text "start"]
      , p [] [text (.debug model)]
      ]

app =
    StartApp.start
          { init = (initialModel, Effects.none)
          , view = view
          , update = update
          , inputs = []
          }

main =
    app.html
当我运行此操作时,当我单击按钮时,模型将正确更新为“已启动”,但不会触发勾号操作


我可能错过了一些东西,但我不知道在哪里

您缺少任务端口。将此项添加到中,您应该已全部设置:

端口任务:信号(Task.Task Effects.Never())
港口任务=
应用程序任务