(create-class spec)
Create a component, React style. Should be called with a map,
looking like this:
{:get-initial-state (fn [this])
:component-will-receive-props (fn [this new-argv])
:should-component-update (fn [this old-argv new-argv])
:component-will-mount (fn [this])
:component-did-mount (fn [this])
:component-will-update (fn [this new-argv])
:component-did-update (fn [this old-argv])
:component-will-unmount (fn [this])
:reagent-render (fn [args....])} ;; or :render (fn [this])
Everything is optional, except either :reagent-render or :render.
Source
(defn
create-class
"Create a component, React style. Should be called with a map,\n looking like this:\n\n {:get-initial-state (fn [this])\n :component-will-receive-props (fn [this new-argv])\n :should-component-update (fn [this old-argv new-argv])\n :component-will-mount (fn [this])\n :component-did-mount (fn [this])\n :component-will-update (fn [this new-argv])\n :component-did-update (fn [this old-argv])\n :component-will-unmount (fn [this])\n :reagent-render (fn [args....])} ;; or :render (fn [this])\n\n Everything is optional, except either :reagent-render or :render."
[spec]
(comp/create-class spec))