       when 'b-attr'
         attr.value.split(/\s*,\s*/).forEach (a) ->
           [n, v] = a.split /\s*:\s*/
-          attributes.push
+          attrs.push
             name: n
             value: get v, context
       when 'b-html'

          value: text
        ]
      else
        attributes.push attr
  children = children.reduce (c, child) ->
    c.concat renderElement child, context
  , []
  [{ type, name, attributes, children, events }]

renderElements = (element, context) ->
  type = element.type
  name = element.name
  children = element.children.slice()
  attributes = element.attributes.filter (i) ->
    i.name isnt 'b-repeat'
  attr = getAttr element, 'b-repeat'
  match = attr.value.match /^\s*(\w+)\s*in\s*(\w+)\s*$/

    attr = element.attributes.filter((i) -> i.name is 'b-if')[0]
    value = get attr.value, context
    return [] unless value
  { type, name, children, attributes } = element
  attrs = []
  events = []
  attributes.forEach (attr) ->
    switch attr.name
      when 'b-on'
        attr.value.split(/\s*,\s*/).forEach (a) ->
