 ATTR_WHITELIST = ['href', 'src', 'target']
 
 $ = React.createElement
-defaultHTMLWrapper = React.createClass
-  _update: ->
-    current = @props.html
-    if @_lastHtml isnt current
-      @_lastHtml = current
-      node = @refs.htmlWrapper.getDOMNode()
-      node.contentDocument.body.innerHTML = @props.html
-      node.style.height = node.contentWindow.document.body.scrollHeight + 'px'
-      node.style.width  = node.contentWindow.document.body.scrollWidth  + 'px'
-
-  componentDidUpdate: -> @_update()
-  componentDidMount: -> @_update()
-
-  render: ->
-    $ 'iframe',
-      ref: 'htmlWrapper'
-      html: @props.html
-      style:
-        border: 'none'
 
 toChildren = (node, parentKey, tableAlign = []) ->
   return (for child, i in node.children

    else
      throw node.type + ' is unsuppoted node type. report to https://github.com/mizchi/md2react/issues'

htmlWrapperComponent = null
module.exports = (raw, options = {}) ->
  htmlWrapperComponent = options.htmlWrapperComponent ? defaultHTMLWrapper
  sanitize = options.sanitize ? true
  highlight = options.highlight ? (code, lang, key) ->
    $ 'pre', {key, className: 'code'}, [

isValidDocument = (doc) ->
  parsererrorNS = (new DOMParser()).parseFromString('INVALID', 'text/xml').getElementsByTagName("parsererror")[0].namespaceURI
  doc.getElementsByTagNameNS(parsererrorNS, 'parsererror').length == 0

getPropsFromHTMLNode = (node, attrWhitelist) ->
  string =
