 
 (def state (r/atom {:server "http://localhost:8080"
                     :playlist []
-                    :tracks []}))
+                    :tracks []
+                    :query ""}))
 
 (defn update-state! [k value]
   (swap! state assoc k value))

  [:input {:type "button" :value "Enqueue"
           :on-click #(enqueue-track track)}])

(defn tracks-div []
  (js/setTimeout get-tracks 1000)
  [:div [:h2 "Tracks"]
   [:ul (for [track (@state :tracks)]
          [:li
           (enqueue-button track)


(defn get-tracks []
  (GET (str (@state :server) "/api/tracks")
       {:params {:q (@state :query)}
        :handler #(update-state! :tracks (% "items"))
        :response-format :json}))

(defn enqueue-track [track]
