Clojurians
#cljsrn
<
2016-07-09
>

This page is not created by, affiliated with, or supported by Slack Technologies, Inc.

misha00:07:36

oh my! 60 fps UI on iphone 5 device :aw_yeah:

(def ReactNative (js/require "react-native"))
(def interaction-manager (.-InteractionManager ReactNative))

(defn on-click [f]
  (fn []
    (.-requestAnimationFrame js/window
      #(.runAfterInteractions interaction-manager f))))

...
(touchable-highlight {:onPress (on-click #(...))}