   (-velem-simple-element [this] this)
   (-velem-insert [this vparent vnext-sibling]
     (set! parent vparent)
-    (.ensureNode this)
-    (dom-insert parent node vnext-sibling)
-    (.onAttached this)
+    (if-let [diff-head (get-diff-head)]
+      (ui/velem-replace this diff-head)
+      (do
+        (.ensureNode this)
+        (dom-insert parent node vnext-sibling)
+        (.onAttached this)))
     this)
   (-velem-take [this]
     (dom-remove node)) 
   (-velem-replace [this old-velem]
-    (.ensureNode this)
-    (if-let [old-node (ui/velem-native-element old-velem)]
-      (do
-        (dom-simple-replace node old-node)
+    (if-let [old-simple (ui/velem-simple-element old-velem)]
+      (when-not (.diffReplace this old-simple)
+        (.ensureNode this)
+        (dom-simple-replace node (ui/velem-native-element old-simple))
         (r/dispose old-velem))
-      (dom-remove-replace node old-velem))
+      (do
+        (.ensureNode this)
+        (dom-remove-replace node old-velem)))
     (.onAttached this)
     this)
   (-velem-lifecycle-callback [this cb-name]

    (when handler
      (unlisten! node event-name handler)))
  (dispose [this]
    (.unlisten this)
    (set! (.-disposed this) true)))

(defn- bind-event! [node event-name handler]
  ((EventBinding. node (name event-name) nil) handler))

    node)
  (-velem-simple-element [this] this)
  (-velem-insert [this vparent vnext-sibling]
    (if-let [diff-head (get-diff-head)]
      (ui/velem-replace this diff-head)
      (do
        (.ensureNode this)
        (set! parent vparent)
        (dom-insert parent node vnext-sibling)))
    this)
  (-velem-take [this]
    (dom-remove node)) 
