 
 (def example-b
   {"example_b" {:type :notebook
+                :id "example_b"
                :pages ["root"]}
    "root" {:type :page
+           :id "root"
            :args ["x"]
            :steps ["result"]}
    "result" {:id "result"


(def example-a
  {"example_a" {:type :notebook
                :pages ["root"]}
   "root" {:type :page
           :args ["a" "b" "c"]
           :steps ["b_squared" "four" "four_a_c" "result"]}
   "b_squared" {:type :call
                :ref {:type :ref/js
                      :js "cljs.core._STAR_"}
                :args [{:type :ref/id :id "b"} {:type :ref/id :id "b"}]}
   "four" {:type :constant
           :data 4}
   "four_a_c" {:type :call
               :ref {:type :ref/js
                     :js "cljs.core._STAR_"}
               :args [{:type :ref/id :id "four"} {:type :ref/id :id "a"} {:type :ref/id :id "c"}]}
   "result" {:type :call
             :ref {:type :ref/js
                   :js "cljs.core._"}
             :args [{:type :ref/id :id "b_squared"} {:type :ref/id :id "four_a_c"}]}})

         (every? #(branch! index %) (:branches x))))

(deftraced step! [index x] [x]
  (check (id! index (:id x)))
  (case (:type x)
    :call (call! index x)
    :constant (constant! index x)
