Fork me on GitHub
#cljsrn
<
2016-08-24
>
vikeri12:08:05

So if someone is keen it should be technically doable now at least :thumbsup:

misha12:08:13

@vikeri too bad I don't use re-frame 🙂 but I'll spend some time reading out reactotron for low hanging cljs fruit

vikeri12:08:01

@misha Alight, if I understood correctly the majority of the benefits comes if you have an FRP style loop with events and subscriptions. But I could be wrong. Good luck!

pvinis12:08:24

is there a template for electron + re-natal?

surreal.analysis12:08:19

If I understand the ecosystem correctly, re-natal is just focused on React Native, whereas electron renders HTML

surreal.analysis12:08:32

So I think you’d be looking for electron + re-frame, independent of re-natal

surreal.analysis13:08:33

I used this months ago - https://github.com/ducky427/electron-template - and was able to get something up and running, but didn’t go very far with it

tianshu15:08:21

I'm using refresh-control like this:

(def home
  (r/create-class
   {:get-initial-state
    (fn [this]
      {:refreshing false})
    :render
    (fn [this]
      (let [on-refresh (fn []
                         (js/setTimeout #(r/set-state this {:refreshing false})
                                        8000)
                         (r/set-state this {:refreshing true}))]
        [ui/scroll-view {:bounces true
                         :refresh-control
                         (r/as-element
                          [ui/refresh-control
                           {:refreshing (:refreshing (r/state this))
                            :title "loading"
                            :tint-color "red"
                            :on-refresh on-refresh}]) }
         [ui/view {:background-color "red"
                   :height 300}]]))}))
on IOS, the indicator circle will disappear after about 1s after pulling, then the screen will scroll back.

tianshu15:08:52

but during this time, the refreshing is false until I set it to true 8s later.

tianshu15:08:33

search for some usage for RefreshControl in cljs.