There are no restrictions on events and attributes (although some attributes may need a special handler if they don't work properly with setAttribute - please submit an issue on github). Looking at your code, maybe the issue is the event handler names - I believe the DOM events are called dragstart, dragend, etc. without a hyphen.
On Mon, Dec 1, 2014 at 10:39 AM, Sven Richter <sver...@googlemail.com> wrote: > Hi, > > I am currently trying to make drag and drop work with freactive, but fail > so far. This is my code: > [:thead [:tr > (for [col (first (:content struct))] > [:td [:div {:draggable true > :on-drag-start (fn [e] (println "dragged")) > :on-drag-over (fn [e] (.preventDefault e)) > :on-drag-enter (fn [e] (.preventDefault e)) > :on-drop (fn [e] (.preventDefault e)(println > "dropped")) > :on-drag-end (fn [_] (println "drag end"))} > col] > ])]] > > But nothing happens, no matter what I try. Are there any restrictions? > Should this be done in a different way? > > Best Regards, > Sven > > Am Montag, 17. November 2014 03:20:29 UTC+1 schrieb Aaron Craelius: > > freactive (pronounced "f reactive" for functional reactive) is a new > high performance, pure Clojurescript, declarative DOM library: > https://github.com/aaronc/freactive > > > > It has a syntax very similar to that of Reagent and was in fact inspired > by Reagent, Om, and others. > > > > I came up with it when I was doing some DOM programming after having > spending a fair amount of time working with JavaFX (see my soon to be > announced library fx-clj: https://github.com/aaronc/fx-clj). I thought Om > and Reagent were very nice to work with (and actually inspired some what I > did with fx-clj), but I felt from my desktop GUI experience, that I could > take things a few steps further. > > > > freactive's main advantages over existing solutions are probably > built-in animations support and slightly higher performance. > > > > Here are it's goals from the README: > > Provide a simple, intuitive API that should be almost obvious to those > familiar with Clojure (inspiration from reagent)Allow for high-performance > rendering good enough for animated graphics based on a purely declarative > syntaxAllow for reactive binding of any attribute, style property or child > node > > Allow for coordinated management of state via cursors (inspiration from > om)Provide deeply-integrated animation supportAllow for cursors based on > paths as well as lenses > > Provide a generic items view component for efficient viewing of large > data sets > > Minimize unnecessary triggering of update eventsCoordinate all updates > via requestAnimationFrame wherever possibleBe easy to debug > > Be written in pure Clojurescript > > Provide support for older browsers via polyfills (not yet implemented) > > Any feedback is welcome!! > > I'm not sure I like the name "freactive" - but it was the best I could > think of at the time. Suggestions for alternative names are welcome. > > -- > Note that posts from new members are moderated - please be patient with > your first post. > --- > You received this message because you are subscribed to a topic in the > Google Groups "ClojureScript" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/clojurescript/99myJ9vLeKQ/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > clojurescript+unsubscr...@googlegroups.com. > To post to this group, send email to clojurescr...@googlegroups.com. > Visit this group at http://groups.google.com/group/clojurescript. > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.