Skip to content

Instantly share code, notes, and snippets.

@aamedina
Created October 17, 2013 15:36
Show Gist options
  • Select an option

  • Save aamedina/7027135 to your computer and use it in GitHub Desktop.

Select an option

Save aamedina/7027135 to your computer and use it in GitHub Desktop.
(defcomponent Metric [resource entity metric-name metric]
ui/IComponent
(-create-dom
[this]
[:ul.list-group
[:li.list-group-item
[:h5.metric-header.list-group-item-heading (str "0 " metric-name)]]
[:li.list-group-item [:small.list-group-item-text "$0.00 CPE"]]
[:li.list-group-item
[:small.list-group-item-text "$0.00 " "Engagement Rate"]]])
(-on-enter
[this]
(js/console.log "enter!"))
(-on-update
[this]
(let [chart (:parent this)]
chart))
(-on-exit [this])
ui/IMouseTarget
(-on-action
[this e]
(js/console.log e)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment