title: How to propagate clicks signal to model update in Elm?
body: <p>I'm writing a game in Elm and in this game there's a button that when pressed should reset the game board to its initial state. I don't understand however how a button click signal is to be propagated to the board model's update function. In the code below, I've just passed the unit value to <code>stepBoard</code> but I can't do much with it so how can I solve it? </p>
  
  <pre><code>--MODEL
  type Board = [(Int,Int)]
  type Game = {name: String, board: Board}
  defaultGame = {name = "Test", board = [(3,3)]}
  
  --UPDATE
  stepBoard click (colsInit, rowsInit) (rows, cols) g = 
            {g | board &lt;- if ? then --some initial value (colsInit, rowsInit)
                          else      --some updated value using (rows, cols)} 
  stepGame: Input -&gt; Game -&gt; Game                                      
  stepGame {click, name, rowsColsInit, rowsCols} g = stepBoard click (0,0) (0,0) g
  game = foldp stepGame defaultGame input
  
  --INPUT
  type Input = {click:(), name: String, rowsColsInit: (Int,Int), rowsCols: (Int,Int)}
  input = Input &lt;~ clicks ~ nameSignal ~ rowsColsInitSignal ~ rowsColsSignal
  
  --VIEW
  (btn, clicks) = Input.button "Click"
  </code></pre>