 (defonce time-updater (js/setInterval
                         #(dispatch [:timer (js/Date.)]) 1000))
 
+
 (def initial-state
-  {:attempts 0
-   :word "portatil"
+  {:word "portatil"
    :key ""
    :guessed-letters #{}
    :failed-letters #{}})

    ;; new value
    [db [_ value]]
    (assoc db :timer value)))    ;; return the new version of db


(register-handler

 :attempts
 (fn
   [db _]
   (let [failed-letters (reaction (:failed-letters @db))]
     (reaction (count @failed-letters)))))


(register-sub
