diff --git a/src/cloact/impl/component.cljs b/src/cloact/impl/component.cljs index d19a290..ff6842a 100644 --- a/src/cloact/impl/component.cljs +++ b/src/cloact/impl/component.cljs @@ -54,8 +54,7 @@ ;; tricky. The upside is that we don't have to do any allocations. (defn- args-of [C] - (-> C (aget "props") .-cljsArgs) - #_(-> C .-props .-cljsArgs)) + (-> C (aget "props") .-cljsArgs)) (defn- props-in-args [args] (let [p (nth args 1 nil)] @@ -95,7 +94,7 @@ ;;; Function wrapping (defn- do-render [C f] - (let [res (f (cljs-props C) C (aget "state" C) #_(.-state C)) + (let [res (f (cljs-props C) C (.-state C)) conv (if (vector? res) (tmpl/as-component res) (if (fn? res) @@ -121,8 +120,7 @@ ;; reset! doesn't call -notifyWatches unless -watches is set (set! (.-watches C) {}) (when f - (set! (.-cljsOldState C) (merge (aget "state" C) - #_(.-state C) (f C))))) + (set! (.-cljsOldState C) (merge (.-state C) (f C))))) :componentWillReceiveProps (fn [C props] @@ -161,8 +159,6 @@ f)) (defn- get-wrapper [key f name] - ;; (when (and name (fn? f) (nil? (aget f "displayName"))) - ;; (aset f "displayName" (str name key))) (let [wrap (custom-wrapper key f)] (when (and wrap f) (assert (fn? f)