         (if (end-game? @word @guesses @misses)
           :end 
           :play))))))
-
-
-
-
-
-
-
-
-
-
-(register-sub
-  :visible-todos
-  (fn [db _]
-      (reaction (let [filter-fn (filter-fn-for (:showing @db))
-                      todos     (vals (:todos @db))]
-                     (filter filter-fn todos)))))
-
-(register-sub
-  :completed-count
-  (fn [db _]
-      (reaction (completed-count (:todos @db)))))
-
-(register-sub
-  :footer-stats
-  (fn [db _]
-      (reaction
-        (let [todos (:todos @db)
-              completed-count (completed-count todos)
-              active-count    (- (count todos) completed-count)
-              showing         (:showing @db)]
-             [active-count completed-count showing]))))  ;; tuple

   [db _]
   (reaction (:misses @db))))


(register-sub
 :key
 (fn

  (:require-macros [reagent.ratom :refer [reaction]])
  (:require [re-frame.core :refer [register-sub]]))

(def max-attempts 5)


(register-sub
 :word
