   (:require-macros
     [devcards.core :as dc :refer [defcard deftest defcard-rg]]
     [reagent.ratom :refer [reaction]]
+    [cljs.test :refer [testing is]]
     ))
 
 (enable-console-print!)

  (valid? [this]
    (empty? errors)))

(defn create-form [value validator]
  (->Form (reagent/atom {::value    value
                         ::original value
                         })
          #(->ValidationResult (-> %
                                 (st/validate validator)
                                 first))))

(defn handle-str-value [field]
  #(set-str-value! field (-> % .-target .-value)))


  Value
  (value [this]
    (reaction (get @value ::value)))
  (value [this default]
    (reaction (get @value ::value default)))
  (set-value! [this val]
    (swap! value
