 
 (enable-console-print!)
 
+; Storages
+
 (def local-storage js/localStorage)
 (def session-storage js/sessionStorage)
+
+; Serialization & deserialization
 
 (defmulti serialize type)
 (defmethod serialize :default

  ILookup
  (-lookup
    ([s key]
       (->
        (.getItem s (serialize key))
        deserialize)))
  ; TODO arity 3
)

(defn clear! [storage] (.clear storage))


  (assoc! local-storage :foo :bar)
  (assert (= 1 (count local-storage)))
  (assert (contains? local-storage :foo))
  (assert (= 0 (count session-storage)))

  (dissoc! local-storage :foo)
