Skip to content

Instantly share code, notes, and snippets.

@jimberlage
Last active July 24, 2018 19:25
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 jimberlage/2d3f99b2d0c4fb3e4359268ac7fc53b8 to your computer and use it in GitHub Desktop.
Save jimberlage/2d3f99b2d0c4fb3e4359268ac7fc53b8 to your computer and use it in GitHub Desktop.
Integrating datedropper with reagent
(ns demo.core
(:require [reagent.core :as reagent]))
(defn my-date-input []
(let [input-el (atom nil)]
(reagent/create-class
{:component-did-mount #(.dateDropper (js/$ @input-el))
:reagent-render (fn []
[:input {:ref #(reset! input-el %) :type "text"}])})))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment