This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-01-26
Channels
- # aatree (6)
- # admin-announcements (2)
- # aws (1)
- # beginners (46)
- # boot (341)
- # braid-chat (3)
- # cider (20)
- # clara (1)
- # cljs-dev (3)
- # cljsjs (7)
- # cljsrn (73)
- # clojure (63)
- # clojure-art (4)
- # clojure-dev (3)
- # clojure-russia (83)
- # clojurescript (77)
- # core-async (12)
- # core-matrix (2)
- # cursive (9)
- # data-science (1)
- # datomic (14)
- # dirac (3)
- # emacs (9)
- # hoplon (3)
- # immutant (8)
- # ldnclj (80)
- # luminus (13)
- # mount (7)
- # off-topic (4)
- # om (288)
- # onyx (20)
- # overtone (5)
- # pedestal (10)
- # perun (3)
- # proton (103)
- # quil (1)
- # re-frame (3)
- # reagent (13)
- # ring-swagger (7)
- # yada (43)
@mihaelkonjevic: it looks pretty interesting. I will try to dig a little deeper later. Thank you.
@pepe: I will work on the readme and docs these days, so make sure you ask me if anything is not clear. I really want to write good docs for this
@mihaelkonjevic: only question I have, why you do not use github? Just for my info, nothing against bitbucket 😉
Because of the free private repos :) they were not public until yesterday. I'll be moving it to github soon
@mihaelkonjevic: read the overview... nice work, i like the routing concepts. will read the sample project when time permits... btw. dobro ime:)
Hi Clojurians! I have a little problem... I'm trying to make a draggable div but I don't succeeded to put on-drag event. My code looks like this: (defn resizable-handle [state]
(let [id (str "handler_" (rand 10000))]
(r/create-class
{
:reagent-render (fn [state]
[:div.ui-resizable-div
{
:id id
:style {
:marginLeft (- (int (get-in state [:user :column_size])) 10)
}
}
]
)
:component-did-mount (
fn [this]
(.draggable
(js/$ (r/dom-node this)
;; {:axis "x"
;; :onDrag (fn[event]
;; (print 1 event (.-clientX event))
;; )
;; }
)
{
:on-drag (fn[event]
(print 12 event (.-clientX event))
)
}
)
)
}
)
)
)
Can anyone tell me what am I doing wrong? Thnaks!
You're putting closing parens and brackets on a single line. They're very lonely like this!
I found the problem. (defn resizable-handle [state] (let [id (str "handler_" (rand 10000))] (r/create-class { :reagent-render (fn [state] [:div.ui-resizable-div { :id id :style { :marginLeft (- (int (get-in state [:user :column_size])) 10) } } ] ) :component-did-mount ( fn [this] (.draggable (js/$ ".ui-resizable-div") (clj->js { ;; :onDrag (fn[] (print 10)) ;; :on-drag (fn[] (print 11)) ;; :on_drag (fn[] (print 11)) ;; :stop (print 1111) :drag (fn[event, ui] (print 12 event (.-clientX event)) ) }) ) ) } ) ) )
@valicimpoeru: please take look at formating code on slack. And as @mbertheau pointed out, consider collecting parens and brackets on single line. It will much more readable. Thank you
Ok, thank you for observation and sorry!