   (navigate-to (:href ac-result))
   false)
 
-;; from https://github.com/swannodette/async-tests
-
-(defn throttle
-  ([source msecs]
-     (throttle (chan) source msecs))
-  ([c source msecs]
-     (go
-       (loop [state ::init last nil cs [source]]
-         (let [[_ sync] cs]
-           (let [[v sc] (alts! cs)]
-             (condp = sc
-               source (condp = state
-                        ::init (do (>! c v)
-                                   (recur ::throttling last
-                                     (conj cs (timeout msecs))))
-                        ::throttling (recur state v cs))
-               sync (if last
-                      (do (>! c last)
-                          (recur state nil
-                            (conj (pop cs) (timeout msecs))))
-                      (recur ::init last (pop cs))))))))
-     c))
-
 (defn maybe-nav [e app ac-results]
   (when app
     (let [ctrl? (.-ctrlKey e)

                 (> (count ac-results) 0))
        (anim/scroll-into-view (om/get-node owner (:highlighted-index app)) {:pad 30})))
    om/IRenderState
    (render-state [this {:keys [internal-text-chan text]}]
      (dom/form {:class "search"
                 :autoComplete "off"
                 :on-submit #(search-submit (nth ac-results highlighted-index))}

                    :placeholder "Looking for? (ctrl-s)"
                    :name "query"
                    :autoComplete "off"
                    :on-input (throttle 200 #(put-text % text-chan owner))
                    :on-key-down #(maybe-nav % app ac-results)})))))

(defn ac-results [{:keys [highlighted-index ac-results]
