trigger an Action from the Update function

心已入冬 提交于 2019-12-02 09:58:22

StartApp requires a port for tasks in addition to main. Change your main function and add the tasks port like this and you'll be all set:

app =
  start
    { init = init
    , update = update
    , view = view
    , inputs = []
    }

main =
  app.html

port tasks : Signal (Task.Task Effects.Never ())
port tasks =
  app.tasks
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!