     @iframe = this._createIframe(@container)
     @iframeDoc = @iframe.contentWindow.document
     @doc = new Tandem.Document(@iframeDoc.body)
-    @iframeDoc.body.addEventListener('DOMSubtreeModified', _.debounce((event) ->
-      console.log 'DOMSubtreeModified', event
+    @ignoreDomChanges = false
+    @iframeDoc.body.addEventListener('DOMSubtreeModified', _.debounce( ->
+      return if @ignoreDomChanges
+      # Normalize
+      # Detect changes
+      # Callback
+      console.log 'DOMSubtreeModified'
     , 100))
 
   _appendStyles: (doc) ->

    return iframe

  insertAt: (startIndex, text, attributes = {}) ->
    this.preserveSelection(range, text.length, ->

    )
    # 1. Save selection
    # 2. Split text into lines
    # 3. Find node where it starts

        )
      )
    )
    @ignoreDomChanges = false
    
  preserveSelection: (modificationRange, charAdditions, fn) ->
    currentSelection = this.getSelectionRange()
