       parent = lastParent()
 
       # TODO: Work when rendering many sibling elements
-      items.observe (newItems) ->
-        replace elements, newItems
-
-      replace = (oldElements, items) ->
+      items.observe ->
+        replace elements
+
+      replace = (oldElements) ->
         elements = []
-        items.forEach (item, index, array) ->
+        items.each (item, index, array) ->
           element = fn.call(item, item, index, array)
 
           if isFragment(element)

  node.nodeType is 11

valueBind = (element, value) ->
  element.value = value()

  # Because firing twice with the same value is idempotent just binding both
  # oninput and onchange handles the widest range of inputs and browser
  # inconsistencies.
  element.oninput = ->
    value(element.value)
  element.onchange = ->
    value(element.value)

  value.observe? (newValue) ->
    element.value = newValue

  switch element.nodeName
    when "SELECT"
      # HACK: Need to set the value, but probably don't have the option contents yet
      # so let's just do it after our execution suspends and we probably have them
      setTimeout ->
        element.value = value()
      , 0

  return

Runtime = (context) ->
  stack = []

  return self

module.exports = Runtime

empty = (node) ->
  node.removeChild(child) while child = node.firstChild
