 (defn ^:export start-app [uri-path]
   (start-history!) ; in Chrome this triggers an event,
                    ; leading to a (routes) call
-  (routes uri-path))+  (execute-routes! uri-path))
  (events/listen @*h*
                 event-type/NAVIGATE
                 (fn [e]
                   (routes global/document.location.pathname))))

; FIXME: get rid!
(defn get-feed-from-uri []
  (let [parts (re-find #"/admin/([^/]+)/(.*?)"
                       global/document.location.pathname)]
    ;; TODO: throw error if feed isn't found
    (when (= 3 (count parts))
      (nth parts 1))))

(defn chop-path [path]
  (rest (string/split path #"/")))

;; limitations under the License.

(ns vix.core
  (:use-macros [vix.macros :only [routes]])
  (:require [vix.views.editor :as editor]
            [vix.views.feed :as feed]
            [goog.global :as global]
