Use .. to access event props in demo bmi calc

This commit is contained in:
Juho Teperi 2017-11-02 21:38:02 +02:00
parent 81344fd61b
commit 2a54e5136e
1 changed files with 1 additions and 1 deletions

View File

@ -81,7 +81,7 @@
[:input {:type "range" :value value :min min :max max [:input {:type "range" :value value :min min :max max
:style {:width "100%"} :style {:width "100%"}
:on-change (fn [e] :on-change (fn [e]
(swap! bmi-data assoc param (.-target.value e)) (swap! bmi-data assoc param (.. e -target -value))
(when (not= param :bmi) (when (not= param :bmi)
(swap! bmi-data assoc :bmi nil)))}]) (swap! bmi-data assoc :bmi nil)))}])