                :cljs [cljs.core.async.impl.protocols :as ap])
             #?(:clj  [clojure.core.async :as a]
                :cljs [cljs.core.async :as a])
+            [ow.clojure :as owc]
             [ow.starbuck.protocols :as p]
             #_[ow.starbuck.core :refer [defcomponentrecord] :as oc]
             ))


  (def ruleset1
    {:units
     {:browser
      #{:overbooked-checker :booker}
      :server
      #{:auth-checker}}

     ;;; you can have many routes
     :routes

         ::transition-count 0
         ::max-transitions max-transitions))

(defn dispatch [{:keys [unit] :as router} msg]
  (let [component (peek (::component msg))]
    (cond (fn? component)                   [true  (component msg)]
          (satisfies? ap/Channel component) [true  (a/put! component msg)]
