Skip to content

Instantly share code, notes, and snippets.

@dupuchba
Last active March 16, 2017 19:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dupuchba/c263306931800788b8b0251a4ebfef9b to your computer and use it in GitHub Desktop.
Save dupuchba/c263306931800788b8b0251a4ebfef9b to your computer and use it in GitHub Desktop.
(defui App
static om/IQuery
(query [this]
[{:app/lists (om/get-query ElementList)}
:elements/dragged])
Object
(render [this]
(let [{:keys [app/lists elements/dragged]} (om/props this)]
(dom/div nil
(dom/h1 nil "Lists with draggable behavior !")
(map #(element-list (om/computed % {:dragging (-> this om/props :elements/dragged)})) lists)))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment