This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-09-02
Channels
- # admin-announcements (21)
- # announcements (1)
- # boot (128)
- # cider (18)
- # cljs-dev (10)
- # clojure (112)
- # clojure-brasil (2)
- # clojure-italy (4)
- # clojure-japan (12)
- # clojure-russia (38)
- # clojurescript (241)
- # clojutre (1)
- # datascript (2)
- # datomic (3)
- # events (1)
- # hoplon (38)
- # jobs (1)
- # ldnclj (5)
- # melbourne (8)
- # off-topic (2)
- # om (9)
- # re-frame (13)
- # reagent (43)
- # sneer-br (24)
- # sydney (3)
What techniques are there for incorporating animation into an Om app? At the moment I'm using the 3rd party "Velocity" lib and sending messages via channels but this feels too contrived
I can utilise the stock life cycle events to get something to show via did-mount. But when it came to animating the disappearance of something I thought I could just use will-unmount, however it seems the DOM element is unloaded before my animation kicks in
@teamaverage: I'm not sure if this would help or not, and I'm not 100% sold on the approach myself, but here it is: https://github.com/omcljs/om-cookbook/tree/master/recipes/animator
@teamaverage: also this semi-related issue with CSS animations and core.async: http://dev.clojure.org/jira/browse/ASYNC-131
@teamaverage: would love to know what you come up with by way of a solution. How do you like Velocity?
Thanks for the link @meow I'll check it out : )
@meow: After thinking about it a little more, I can clarify by saying I know of a few ways to achieve animation but I'd like the most idiomatic way; one that doesn't go against the grain of React/Om
The simple thing I'm aiming to get working is a button-toggle dropdown where the button is a component (i.e. with its own life cycle methods) and so is the drop-down but both live in the same namespace
The latest technique is I'm just passing a map of state through to om/build when I'm constructing the drop-down. I've a function which converts this state {:show-results true/false} to a velocity call.